The document provides an overview of extensibility features in Microsoft Dynamics CRM. It discusses how the software is designed to be extended affordably and adapted to business needs through features like custom workflow activities, plug-ins, client-side scripting, web services, and custom web pages. It also outlines the skills needed for developers, such as .NET, JScript, and using the Microsoft Dynamics CRM SDK. Resources for developers are highlighted, including the SDK, online communities, code samples, support, and certification.
1. Chapter 1: Extensibility Overview
CHAPTER 1: EXTENSIBILITY OVERVIEW
Objectives
The objectives are:
• Understand how Microsoft Dynamics CRM is designed to be
extended.
• Tried Removing Lesson Objetive for Extensibility Features
• Examine the skills developers will use to extend Microsoft Dynamics
CRM.
• Identify the resources that are available to support developers.
Introduction
Microsoft Dynamics® CRM is designed for extensibility. Business applications
must support the specific business practices and interconnected processes that are
unique to each business. The unique requirements of each implementation
require capabilities that allow the application to enable solutions that meet the
needs of the organization.
This course provides an introduction to the following courses with a high level
overview of features provided to extend Microsoft Dynamics CRM 4.0.
1-1
2. Extending Microsoft Dynamics® CRM 4.0
Microsoft Dynamics CRM Design Focus
Microsoft Dynamics CRM is designed to enable two key concepts:
• Affordable Adaptability
• Adaptive Process
Affordable Adaptability
Microsoft Dynamics CRM enables an organization to achieve a CRM solution
that fits its unique needs at an affordable cost. It is designed to:
• Work the way you do. Microsoft Dynamics CRM is tightly
integrated with Microsoft® Office and Microsoft® Office Outlook®. It
overcomes possible adoption issues by providing CRM features and
functionality in a manner that is familiar to the Microsoft
applications many organizations already use.
• Work the way your business does. Microsoft Dynamics CRM 4.0
introduces several new features in addition to the CRM features
included in earlier versions. These new features include the
following:
o Multi-Currency
o Multilingual User Interface
o Multi-Tenancy
o New entity relationship types, including Many-to-Many
relationships
o Improved Workflow and Reporting
o Availability of Workflow maintenance to end-users
o Improved Data Migration and Data Importation
The core customization features of Microsoft Dynamics CRM allow for many
features to be easily and inexpensively customized meeting the needs of most
organizations.
• Work the way technology should. Microsoft Dynamics CRM
works the way an IT staff wants it to because it is based on proven,
industry-standard Microsoft technology that is easy to learn and
work with. For developers, the Software Development Kit (SDK)
provides a deep integration with Microsoft® Visual Studio® .NET. By
using IntelliSense and strongly typed classes, it allows for code to be
developed more quickly and at a reduced cost.
1-2
3. Chapter 1: Extensibility Overview
Adaptive Process
Although Microsoft Dynamics CRM has introduced new features in version 4.0,
no CRM product can ever create a solution to meet the needs of every
organization without some configuration or extension. As a business evolves, its
CRM solution must be adaptable to stay synchronized with the business.
Microsoft Dynamics CRM is designed to be adapted to meet these requirements
depending on the area of expertise for:
• Non-Developers. The ability to create new entities in Microsoft
Dynamics CRM, without the requirement to write custom code,
enables businesses to customize Microsoft Dynamics CRM
according to their own business model. Microsoft Dynamics CRM
continues to allow for easy customizations of forms and views
through an easy to use interface. Finally, Workflow tools in
Microsoft Dynamics CRM can be used to create powerful automated
business processes.
• Developers. For developers, the adaptive process goes even further.
It is much easier for developers to interact with the Microsoft
Dynamics CRM Web services. The capabilities to include Plug-ins
are improved with a new Plug-in model. Workflows can now use an
extended set of .NET assemblies to provide more flexibility.
Extensibility Features
There are five features where a developer can extend the functionality of
Microsoft Dynamics CRM:
• Custom Workflow Activities
• Plug-ins
• Client-side scripting
• Web service programming
• Hosting custom Web pages within the Microsoft Dynamics CRM
Web site
NOTE: Developing Microsoft Dynamics CRM reports using SQL Server
Reporting Services could be considered the fifth extensibility feature found in
Microsoft Dynamics CRM 4.0. However, because that capability is primarily
related to tools found within SQL Server Reporting Services, it is not included in
this course.
1-3
4. Extending Microsoft Dynamics® CRM 4.0
Custom Workflow Activities
A workflow action can be defined to include appropriate business logic. The
assembly can accept parameters from the workflow that can be used in the
business logic and return values to the workflow.
There is almost no limit to what can be performed programmatically in the
activity. As soon as the processing is finished, the activity can return data that
can be included in additional logic in the workflow.
Plug-ins
Plug-ins are a way of adding custom business logic to the Microsoft Dynamics
CRM system. A Plug-in component is a .NET assembly that contains custom
Plug-in event handlers. These event handlers are registered with Microsoft
Dynamics CRM and invoked when a particular event occurs on an entity in the
system.
The following are some actions that represent events:
• Create
• Update
• Delete
• Assign
• Retrieve
The assembly can access information about the object that the action is being
performed on and include that information in the logic and actions that are
contained in the assembly. There are two types of Plug-ins in Microsoft
Dynamics CRM:
• Pre-event plug-in. A pre-event plug-in is invoked by the system in
response to an event, but before the event is processed by the system.
For example, a PreCreate Plug-in is invoked before a new entity
instance is created. This provides an opportunity to work with the
data before it is saved to the database. This provides opportunities to:
o Create record numbers.
o Perform Address verification.
o Populate fields not exposed to the user.
• Post-event plug-in. A Post-event plug-in occurs after the action is
completed in Microsoft Dynamics CRM. Data from the object that
the action is performed on can be passed to the assembly to use in
logic and additional actions performed by the assembly. A Post-
event plug-in is typically used to initiate integration with another
system.
1-4
5. Chapter 1: Extensibility Overview
Client-side Scripting
Client-side scripting includes the capabilities to perform business logic and
actions from the Microsoft Dynamics CRM Web or Outlook clients. It also
includes capabilities to add the user interface elements to integrate Microsoft
Dynamics CRM with other applications.
Including business logic and actions on the client allows for immediate
processing without requiring the user to save a record. It uses the user's computer
instead of the server. This results in immediate processing and improved
performance.
Client-side scripting supports the use of JScript code to Microsoft Dynamics
CRM forms. The Microsoft Dynamics CRM SDK provides a scripting guide that
documents how to write and add JScript to read and set data values stored in
form fields. These scripts are added to a form in the Form Customization area
and are invoked in response to one of the following form or field related events:
• OnSave
• OnLoad
• OnChange
Custom buttons, menus, navigation items, and IFrames can also be added to
integrate new capabilities into Microsoft Dynamics CRM.
Web Service Programming
All the extensibility features mentioned enable actions performed in Microsoft
Dynamics CRM to initiate custom business logic and perform actions to extend
Microsoft Dynamics CRM's capabilities. Web service programming enables
other applications to interact with Microsoft Dynamics CRM.
These applications can include the assemblies included in workflow or Plug-ins,
and they can also be ISV solutions or integrations with other business
applications. Or they can be a small executable that performs a specific regularly
scheduled task.
Custom Web Pages
Microsoft Dynamics CRM supplies a mechanism whereby custom Web pages
can be hosted within the Microsoft Dynamics CRM Web site. Links to these
custom pages can be added in several places within the Microsoft Dynamics
CRM application.
The custom Web pages can perform actions against the Microsoft Dynamics
CRM data using Microsoft Dynamics CRM Web services, or can form an
interface to data in separate applications.
1-5
6. Extending Microsoft Dynamics® CRM 4.0
Required Skills
To use all the extensibility features for Microsoft Dynamics CRM a developer
needs the following skills:
• Developing .NET-connected applications by using Visual Studio
• JScript
• DHTML
• XML
• Transact - SQL
• Using the Microsoft Dynamics CRM Customization features
• Using the Microsoft Dynamics CRM Web services.
Developing .NET-connected applications using Visual
Studio
To create plug-ins or custom workflow activities, developers must be able to use
a .NET language such as Visual Basic .NET or C#. Other .NET languages may
also be used.
Technically, .NET-connected applications can be developed and compiled
without Visual Studio . Given the advantages that Visual Studio provides, it is
expected that most developers will use it.
JScript
Client-side scripting must use JScript . JScript is the Microsoft implementation of
the ECMA 262 language specification. With only minor exceptions JScript is a
full implementation of the ECMA standard.
NOTE: VBScript cannot be used in Client-side scripting.
DHTML
DHTML refers to capabilities to work with the Document Object Model (DOM)
in a browser by using style sheets and JScript code.
When performing Client-side scripting with Microsoft Dynamics CRM,
developers reference and set values for objects in the CRM forms and grids.
These objects are displayed within Microsoft® Internet Explorer or within HTML
pages displayed in Outlook.
1-6
7. Chapter 1: Extensibility Overview
XML
Microsoft Dynamics CRM is built upon XML and a developer should
understand how to work with XML documents manually and programmatically.
Transact-SQL
Opportunities to use Transact-SQL in Microsoft Dynamics CRM are limited, but
there are some tasks which may require it, such as writing custom reports. There
are opportunities to retrieve data from specific SQL Server database views within
Microsoft Dynamics CRM. Using Transact-SQL to insert, update, or delete
records in the Microsoft Dynamics CRM database is not supported; these
operations must be performed by using the Microsoft Dynamics CRM Web
services.
Using Microsoft Dynamics CRM Customization Features
The Microsoft Dynamics CRM application includes several core customization
features. These include the following:
• Form Customization
• View Customization
• Creating custom Entities
• Creating custom entity Attributes
• Defining custom entity Relationships
• Creating Workflow rules
• Configuring Event code
This course assumes that participants have completed the prerequisite Microsoft
Dynamics CRM Customization and Configuration training offering or have
equivalent experience. Details on how to perform these tasks is not included in
this course.
Using Microsoft Dynamics CRM Web Services
This course is designed to help developers learn how to use the Microsoft
Dynamics CRM Web services and other skills relevant to extending Microsoft
Dynamics CRM.
1-7
8. Extending Microsoft Dynamics® CRM 4.0
Resources
There are several resources available for developers. There are several resources
available for developers; currently these are the most important.
• Microsoft Dynamics CRM SDK
• Microsoft Dynamics CRM Communities
• MSDN Code Gallery
• MSDN Technical Articles
• Microsoft Dynamics CRM Technical and Developer Support
• Extending Microsoft Dynamics CRM Certification Exam
• ISV Application Certification
• Microsoft Dynamics CRM Implementation Guide
• Microsoft SQL Server Reporting Services
Microsoft Dynamics CRM SDK
The Microsoft Dynamics CRM 4.0 SDK is the most important and definitive
resource for extending Microsoft Dynamics CRM. The Microsoft Dynamics
CRM SDK is frequently updated. Therefore, it is recommended to check
periodically to see whether a new version is going to be released.
The online SDK is available at http://msdn2.microsoft.com/en-
us/library/bb928212.aspx
It is also available as a downloadable executable file from
http://www.microsoft.com/downloads/details.aspx?FamilyID=82E632A7-FAF9-
41E0-8EC1-A2662AAE9DFB&displaylang=en
The Executable file extracts files and folders described in the following table:
Resource Description
SDKReadme.htm Contains release notes.
CrmSdk4_0.chm The documentation Help file for
the SDK.
Binmsidcrl40.dll Types and methods needed for
Windows Live (formerly called
Passport) authentication.
Client Sample code to demonstrate key
topics for the client programming
guide.
1-8
9. Chapter 1: Extensibility Overview
Resource Description
CRM4 UX Design Guide.pdf User interface design guide to help
build applications that are visually
consistent with Microsoft
Dynamics CRM
Server Sample code to demonstrate key
topics for the server.
Tools Tools used for plug-ins.
Walkthroughs Sample code that accompanies
step-by-step instructions.
LicenseTerms.doc The Microsoft Software License
Terms for the SDK.
BinMicrosoft.Crm.Sdk.dll Types and methods needed for
developing plug-ins and
workflows.
BinMicrosoft.Crm.SdkTypeProxy.dll Types and methods needed for
developing plug-ins and
workflows.
Binmsidcrl40.dll Types and methods needed for
Windows Live (formerly called
Passport) authentication.
Installing the SDK allows it to be viewed from Visual Studio .NET 2005. The
Help file cannot be viewed from Visual Studio 2005.
The SDK provides sample code of several Server and Client-side scripting
examples in addition to helper code that can make the development experience
easier.
Web service programming examples are provided in both Visual Basic .NET and
C#.
Microsoft Dynamics CRM Communities
There are several communities related to Microsoft Dynamics products and
these can be accessed from the Microsoft Dynamics Web site.
Included in this is the Microsoft Dynamics CRM Developer community at
http://forums.microsoft.com/Dynamics/ShowForum.aspx?ForumID=489&SiteID
=27.microsoft.com/newsgroups/default.aspx.
1-9
10. Extending Microsoft Dynamics® CRM 4.0
MSDN Code Gallery
The MSDN Code Gallery provides another type of community with advanced
capabilities. There are message boards on more targeted topics than the
communities’ page and users can post code and projects for others. There are also
links to several different resources that include Blogs, and technical articles.
To use the MSDN Code Gallery, visit the following Web site:
http://code.msdn.microsoft.com/Project/ProjectDirectory.aspx?TagName=CRM
Microsoft Dynamics CRM Technical and Developer
Support
There are several available service plans for technical support for Microsoft
Dynamics CRM. Refer to
http://www.microsoft.com/dynamics/crm/support/serviceplans.mspx for more
information.
In the Microsoft Dynamics CRM Technical Support team there is a group
dedicated to supporting developers. If a technical support request involves the
Microsoft Dynamics CRM SDK, the request is routed to them.
Extending Microsoft Dynamics CRM Certification Exam
The primary training course prepares a developer with a good understanding of
methods to extend Microsoft Dynamics CRM and leads to the Extending
Microsoft Dynamics CRM certification exam. This certification allows for an
individual to demonstrate to employers and customers that they have the
knowledge and skills required to develop extensions to Microsoft Dynamics
CRM.
This exam is required for the Microsoft Business Solutions Certified Master -
Microsoft Dynamics CRM Developer certification.
For more information about the Microsoft Business Solutions Certified Master -
Microsoft Dynamics CRM Developer certification refer to:
https://mbs.microsoft.com/partnersource/communities/training/Certifications/exa
mpreparation/MBS_Master_CRM_Dev.htm
ISV Application Certification
Independent Software Vendors (ISVs) who create an application for re-sale
should have their solution certified. This certification is performed by an
independent testing company. The primary criteria are that the solution uses only
supported methods. It does not certify the solution for suitability of purpose.
1-10
11. Chapter 1: Extensibility Overview
When a solution uses only supported methods, organizations who install it can be
assured that it is upgradeable to future versions of Microsoft Dynamics CRM.
Microsoft Dynamics CRM Implementation Guide
The Microsoft Dynamics CRM Implementation Guide is available from the
Microsoft Download Center. The Implementation Guide consists of:
• The Installation Guide: Which provides information about installing
and troubleshooting Microsoft Dynamics CRM.
• The Planning Guide and tools: Which is a guide through several
planning tools that consist of spreadsheets, flowcharts and
worksheets that help to plan and execute a Microsoft Dynamics
CRM Implementation.
Microsoft SQL Server Reporting Services
This course does not focus on opportunities to develop or customize Microsoft
SQL Server Reporting Services Reports for Microsoft Dynamics CRM.
For training on Microsoft SQL Server Reporting Services refer to the Microsoft
Learning Course “Designing a Reporting Solution Architecture using Microsoft
SQL Server 2005 Reporting Services”
http://www.microsoft.com/learning/syllabi/en-us/2797bfinal.mspx. The
Microsoft Dynamics CRM SDK includes the Report Writers Guide that provides
information a report writer can use to create or customize Microsoft Dynamics
CRM reports.
Summary
This course introduced the following:
• Microsoft Dynamics CRM Extensibility features.
• How Microsoft Dynamics CRM is designed to be extended.
• The four main extensibility features for developers.
• The skills that developers need.
• Several resources for developers.
1-11
12. Extending Microsoft Dynamics® CRM 4.0
Test Your Knowledge
1. You want to give non-developers the option to apply custom business logic
during an automated process. What Microsoft Dynamics CRM feature lets
you do this?
( ) Plug-ins
( ) Web service programming
( ) Client-side scripting
( ) Custom Workflow Activities
2. You want to develop an integration between Microsoft Dynamics CRM and
another business system. When a record is created or updated in Microsoft
Dynamics CRM, you want that data to be synchronously added or updated in
the other system. What Microsoft Dynamics CRM feature is the best choice
to achieve this?
( ) Plug-ins
( ) Web service programming
( ) Client-side scripting
( ) Custom Workflow Activities
3. You want to include some data validation in Microsoft Dynamics CRM that
will prevent users from saving a record that does not meet specified criteria.
These criteria depend on data found in the record. Which of the following
represent ways this can be achieved? Select all that apply. (Select all that
apply.)
( ) Plug-ins
( ) Web service programming
( ) Client-side scripting
( ) Custom Workflow Activities
4. You want to develop an integration between another business system and
Microsoft Dynamics CRM. When a record is created or updated in the other
Business system, you want that data to be added or updated in Microsoft
Dynamics CRM. What Microsoft Dynamics CRM feature is the best choice
to achieve this?
( ) Plug-ins
( ) Web service programming
( ) Client-side scripting
( ) Custom Workflow Activities
1-12
13. Chapter 1: Extensibility Overview
5. Which of the following programming languages can be used to develop
assemblies that can be executed from Workflow? Select all that apply.
(Select all that apply.)
( ) Visual Basic 6.0
( ) Visual Basic .NET
( ) C#
( ) C++
6. Which language is used in Client-side scripting in Microsoft Dynamics
CRM?
( ) C#
( ) Visual Basic .NET
( ) JScript
( ) VBScript
7. If you want to download some sample code for Microsoft Dynamics CRM,
or want to upload some code you have written, which resource can you use?
( ) Microsoft Dynamics CRM Communities
( ) Microsoft Download
( ) MSDN Code Gallery
( ) MSDN Communities
1-13
14. Extending Microsoft Dynamics® CRM 4.0
Quick Interaction: Lessons Learned
Take a moment and write down three key points you have learned from this
chapter:
1.
2.
3.
1-14
15. Chapter 1: Extensibility Overview
Solutions
Test Your Knowledge
1. You want to give non-developers the option to apply custom business logic
during an automated process. What Microsoft Dynamics CRM feature lets
you do this?
( ) Plug-ins
( ) Web service programming
( ) Client-side scripting
(•) Custom Workflow Activities
2. You want to develop an integration between Microsoft Dynamics CRM and
another business system. When a record is created or updated in Microsoft
Dynamics CRM, you want that data to be synchronously added or updated in
the other system. What Microsoft Dynamics CRM feature is the best choice
to achieve this?
(•) Plug-ins
( ) Web service programming
( ) Client-side scripting
( ) Custom Workflow Activities
3. You want to include some data validation in Microsoft Dynamics CRM that
will prevent users from saving a record that does not meet specified criteria.
These criteria depend on data found in the record. Which of the following
represent ways this can be achieved? Select all that apply. (Select all that
apply.)
(√) Plug-ins
( ) Web service programming
(√) Client-side scripting
( ) Custom Workflow Activities
4. You want to develop an integration between another business system and
Microsoft Dynamics CRM. When a record is created or updated in the other
Business system, you want that data to be added or updated in Microsoft
Dynamics CRM. What Microsoft Dynamics CRM feature is the best choice
to achieve this?
( ) Plug-ins
(•) Web service programming
( ) Client-side scripting
( ) Custom Workflow Activities
1-15
16. Extending Microsoft Dynamics® CRM 4.0
5. Which of the following programming languages can be used to develop
assemblies that can be executed from Workflow? Select all that apply.
(Select all that apply.)
( ) Visual Basic 6.0
(√) Visual Basic .NET
(√) C#
( ) C++
6. Which language is used in Client-side scripting in Microsoft Dynamics
CRM?
( ) C#
( ) Visual Basic .NET
(•) JScript
( ) VBScript
7. If you want to download some sample code for Microsoft Dynamics CRM,
or want to upload some code you have written, which resource can you use?
( ) Microsoft Dynamics CRM Communities
( ) Microsoft Download
(•) MSDN Code Gallery
( ) MSDN Communities
1-16