Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Error in AutoMapper
Message
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Programmation orienté objet
Titre:
Error in AutoMapper
Versions des environnements
Environment:
C# 4.0
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01605838
Message ID:
01605838
Vues:
62
Hi everybody,

I am getting the following error

AutoMapper.AutoMapperMappingException was unhandled by user code
HResult=-2146233088
Message=Missing type map configuration or unsupported mapping.

Mapping types:
RuntimeType -> Byte
System.RuntimeType -> System.Byte

Destination path:
IEnumerable`1[0].ItemType.ItemType

Source value:
System.String
Source=AutoMapper

On this line of code:
   assignedItems = AutoMapper.Mapper.Map<ItemForDualListViewModel[],
                    IEnumerable<Items>>(editModifierGroupViewModel.AssignedItems.ToArray());
The ItemForDualListViewModel has just a few properties that match properties in the Items class. Items class has many more properties including Byte ItemType.

Why would AutoMapper produce this error?

Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform