Overview

This version of the sample app adds Cortana voice command input to the feature set of the basic Activity Tracker Sample app for Dynamics CRM. Another added feature is that you can pin a CRM contact to the Windows 8 Start screen. the sample is written as a universal Windows 8 app.

Build and run the sample

Your development computer must have an internet connection to build the sample app as one or more Nuget packages will be automatically downloaded during the app build.

To build and run the Activity Tracker Plus Sample app, follow these steps on a Windows 8 development computer running Visual Studio 2012 or 2013.

  1. Download and build the Mobile Development Helper Code for Dynamics CRM.
  2. Follow the instructions in the topic Walkthrough: Register a CRM app with Active Directory to register the app with Active Directory. You must register the app with a claims enabled CRM deployment, which typically means CRM Online or IFD.
  3. Verify that your CRM server is configured for OAuth authentication. The CRM Online servers are pre-configured. For more information on configuring an IFD server running ADFS 2.0 (or later) see Post-installation and configuration guidelines for Microsoft Dynamics CRM.
  4. Modify the ClientId value on line 76 in the file ActivityTracker.Shared/Helper/ActivityTrackerHelper.cs to match the value used during app registration.
  5. In Visual Studio, open the ActivityTrackerPlus.Universal.sln file.
  6. Add a reference to the ActivityTracker.WP and WS projects for the Microsoft.Crm.Sdk.Mobile.dll library that you built in step 1.
  7. Press F6 to build the solution, or F5 to build and run.
  8. When prompted by the app, enter your CRM server organization URL on the Settings page and choose Submit. An example URL for CRM Online (North America) would be https://<myOrg>.crm.dynamics.com.
  9. Enter your login credentials if prompted.
  10. A list of your CRM contacts and a search box is shown. You can select a contact from the list to view contact information or do a search for a contact by name.
  11. When the detailed information on the contact is shown, you can optionally add one or more activities to that contact.

There are two NuGet packages that Visual Studio should download during the first build. If this does not happen and build errors result, you can remove and re-add those packages using the NuGet package manager in Visual Studio. The packages are named Microsoft.IdentityModel.Clients.ActiveDirectory and Newtonsoft.Json.

About the sample

Authentication with the CRM organization web service using ADAL is handled in the file ActivityTracker.Shared/Helper/ActivityTrackerHelper.cs.

Supported voice commands can be found in the file ActivityTracker.Shared/Voice/ActivityTrackerVCD.xml. The command prefix word used to invoke voice command input is "tracker".

The mobile development helper code handles all OData and SOAP message requests to the organization web service.

Important notes

More Information

For more information on Dynamics CRM authentication and app development, see Write mobile and modern apps.

You can find iOS and Android versions of the basic Activity Tracker sample application on GitHub under the organization DynamicsCRM.

Copyright

This document is provided "as-is". Information and views expressed in this document, including URL and other Internet Web site references, may change without notice.

Some examples depicted herein are provided for illustration only and are fictitious. No real association or connection is intended or should be inferred.

This document does not provide you with any legal rights to any intellectual property in any Microsoft product. You may copy and use this document for your internal, reference purposes.

© 2014 Microsoft Corporation. All rights reserved.

Microsoft, Active Directory, IntelliSense, Microsoft Dynamics, Visual Studio, and Windows are trademarks of the Microsoft group of companies.

All other trademarks are property of their respective owners.