When another version of CRM gets out, we all have to learn from 0 few things, and regardless the experience we all have, nobody can deny that sometimes it is frustrating when we experience an error/exception for the first time and more time we spend understanding the "why?" without finding the solution more we feel worst.
What i have found on the very start of the painful task of changing the Javascript code to meet the Web API requirements was that the way i was doing few things related to fields and entities just changed, as an example, the lookup field i wrote on my previous post.
To help me on that tedious task of updating or creating records trough the Web API i found my new best friend regarding that matter, the oData Metadata Service.
For who knows CRM, just go to the Settings – Customizations – Developer Resources – Click to download the oData Metadata, i can tell you that will make your life just much easier when dealing with lookups now in CRM when using them in a custom web resource. In there, you will find the object model used by the Web API.
I have found how i could set a value on a lookup field from that file, the lookups are now the navigation properties, and because of that, sometimes, the Navigation Property name for that specific field is just different from what you used before, and in there you will be able to see what is the name you need to use.
Hope it helps.
Commentaires