Link to home
Start Free TrialLog in
Avatar of AmbassadorSpock
AmbassadorSpockFlag for United States of America

asked on

MVC 4: Several Models in one Model causing an error

I have several Models defined such as RescueFormsAdministration.Models.Account that I have given the name AccountModel and a wrapper Model RescueFormsAdministration.Models.CreateAccountViewModel that contains the Account and other Models in order to pass it to one View. This works until I run it and then I get the error below:
 
"The model item passed into the dictionary is of type 'RescueFormsAdministration.Models.Account', but this dictionary requires a model item of type 'RescueFormsAdministration.Models.CreateAccountViewModel'. "

Does anyone know how to fix the problem?
ASKER CERTIFIED SOLUTION
Avatar of AmbassadorSpock
AmbassadorSpock
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial