json - How to determine cause of "An item with the same key has already been added" exception -


in 1 of projects have class contains lot of properties , lot of interfaces. when class exposed using web api, browser version displays xml-serialized version of class, okay. when use in javascript, json version used , newtonsoft-related exception "an item same key has been added." because xml-serialization work, assume caused duplicate class property name, not know how find culprit.

my question is: how can determine class property causes exception?

is thread modifying structure while serialize it? observed datacontractjsonserializer generate either "collection modified; enumeration operation may not execute." or create json duplicate keys, in turn generates "an item same key has been added." when try read it.


Comments

Popular posts from this blog

apache - Remove .php and add trailing slash in url using htaccess not loading css -

javascript - jQuery show full size image on click -