JavaScript

This section shows how to get and set the address from an Account using JavaScript by querying the CRM OData (REST) Service. This sets the contact address when selecting an Account as the Company Name field automatically (without requiring you to enter it again).

Note

To make this example work, you must select an Account with the address fields populated with some data.

Caution

The following example works only if you select a company name for a Contact and not a parent Contact. However, after reviewing this example, you can modify it to work with parent Contacts if desired.

The purpose of this example is to show how you can consume an OData (REST) Service without having to build a .NET application or component to make some of ...

Get Microsoft Dynamics CRM 2013 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.