serving the solutions day and night


Monday, February 25, 2013

MS Dynamics CRM Solutions

CRM Customizations - Customize through a web-based interface without any programming expertise or use the MS Dynamics CRM software development kit (SDK) to programmatically alter the metadata. Two default security roles associated with system customization privileges: System Administrator and System Customizer

Solutions are packages of customizations and metadata that allow system administrators and software developers to create, transport, and maintain business applications or functionality that run on the Microsoft Dynamics CRM framework.

Settings area -> Click Customizations ->  Click Customize the System to open the solution.

Publisher - If you want to distribute managed solutions, you should create a Publisher. Each solution has a publisher that defines its owner or creator. Dynamics CRM creates a default publisher when an organization is created. The default publisher can be associated to solutions you don’t expect to export. If you plan on deploying any changes to production environments, use your own publisher.
Settings area -> Click Customizations ->  Click Publishers

Publisher Form Fileds -  Display Name (your company name), Name (Unique name for the publisher), Prefix (required, example gab_ the customizations in your entities or fields), Marketplace (This section automatically displays the solution publisher information from the marketplace. The Marketplace solution file will have a .cab extension), ....

Solution - Create, import, export, or Get solutions from MS Dynamics CRM Marketplace. Settings area -> Click Solutions

Solution Form Fileds - Display Name, Name, Publisher, Configuration Page (Associate a web resource component that can be used to configure or further the solution. You could use this field to include an installation help page, a control to configure sample data, adding licensing information, and so on.), Version (major.minor[.build[.revision]] like CRM does not auto-increment), ...

Create a new solution, save and in the Solutions grid, click Add Existing (add entities, Site Map,...)

Solution Components - After you create a solution, you can add or create components to associate to it. Solution contains the following components: Entity and Entity Components (Forms, Fields, Views, Charts, Realtionship),     Option sets, Client Extensions (Site map and application ribbon), Web Resources (Web Pages, Style Sheet, Java Script, XML, Images, Silverlight), Processes (Workflow and dialogs), Plug-in Assemblies, Service Endpoints, Dashboards, Reports, Connection Roles, Templates (Article, Contract, E-mail, and Mail Merge), Security Roles, Field Security Profiles, Remaining Components

CRM Meta -

Client Extensions (Site map and application ribbon) - The site map controls the application areas and links in the left navigation pane of the main application window. The ribbon definition is stored in three places - main application window’s ribbon, associated with the entity grid and form ribbons. The site map and application ribbon are stored as XML files.

Adding the Application Ribbons component to a solution
1. Navigate to the Settings area and click Solutions.
2. Double-click the solution.
3. In the Solutions grid, click Add Existing and select Application Ribbons
4. Microsoft Dynamics CRM adds the Application Ribbons component to the solution components grid. Click Save and Close.

Service endpoints are Windows Azure AppFabric Service Bus endpoints that you can register to your solution so that they’re available in your application customizations. More details

Publishing Customizations - When you made changes on solution components, such as entities and web resources, your users will not immediately see your changes, until you publish the customizations. Several ways to publish your customizations:
Single component -  Settings area -> Solutions -> Click Solution -> Click Entities - > Select the entity -> Click Save -> Click Publish

Multiple components  -  Settings area -> Solutions -> Click Solution -> Click Entities - >  Click Publish All Customization

All components  -  Settings area -> Solutions ->  Click Publish All Customization

Solution Packages Types
Unmanaged - An unmanaged solution is one that is still under development or is not intended to be distributed. All solutions are initially created as unmanaged. In an unmanaged solution, the components you add or create are stored only as references in the solution. Multiple unmanaged solutions can have a reference to the same component, and any changes made to that component will impact the other solutions that contain the component, regardless of which solution was used to make the changes. Those changes also will be included when any solution that references the component is exported.

For instance, let’s assume you have two unmanaged solutions that both include the Account entity as a component. If you make a change to the Account entity, such as moving the addresses on the form, those changes will be seen in both unmanaged solutions, as well as any other solution that includes the Account entity in its components.

Therefore, one of the caveats of an unmanaged solution is that you cannot automatically delete components by simply deleting the solution. To fully remove a custom component, you must manually delete it from the solution or use the Microsoft Dynamics CRM SDK.

Unmanaged Solution - When a solution is unmanaged, you can perform the following actions: Add Remove & Delete components. Export and import the unmanaged solution, Export the solution as a managed solution.

Managed - A managed solution is a completed solution that is intended to be distributed and installed. When a managed solution is exported, its definition is locked, meaning its properties and components cannot be added or removed when the solution is imported into another CRM organization. Managed solutions can  be uninstalled, along with its components from a CRM organization.

Managed Solutions - If you intend to distribute your solution as a managed solution, export your unmanaged solution and select the Managed option in the Package Type dialog box. After you generate a managed solution, you cannot install it in the same CRM organization that contains the unmanaged solution used to create it. It must be installed in a different organization.

After you install a managed solution, the following applies: You cannot add or remove solution components in a managed solution, You cannot export a managed solution,  Deleting a managed solution uninstalls all the solution components within it.

Managed Properties
Managed properties of components provide how a component can be modified after the managed solution is installed.
Settings area -> Solutions -> Click Solution -> Click Entities - > Check the entity -> Click Manageed Properties

Conflict Resolution - When two or more solutions define solution components differently, CRM resolves the conflict using two strategies, Merge and Top Wins.

Merge - User interface components (ribbons, forms, and site map) are merged.

Top Wins -  For all other solution components any conflict is calculated in favor of the customization that is applied last. For managed solutions this usually means that the last solution installed is applied. However, there is a special case when an update to a managed solution is installed.

Time StampChangeResult
S1Install Managed Solution AView name displays Open Contacts Form
Mobile Number label is Mobile
Form E-mail label is E-mail Address
S2Install Managed Solution BView name displays Active Contacts,
Reg Number included in view
Form Mobile Number label is Cell Phone
Form E-mail label is E-mail Address
S3User changes the Active Contacts view name to Active Employees in Unmanaged SolutionView name displays Active Employees
View displays Reg Number column
Form Mobile Number label is Cell Phone
Form E-mail label is E-mail Address
S4Reinstall Managed Solution A and maintain customizationsNo changes from S3
View name displays Active Employees
View displays Reg Number column
Form Mobile Number label is Cell Phone
Form E-mail label is E-mail Address
S5Reinstall Managed Solution A and overwrite customizationsView name displays Open Contacts
View does not display Reg Number column
No form changes from S4
Form Mobile Number label is Cell Phone Form
E-mail label is E-mail Address
S6Uninstall Managed Solution AView name displays Open Contacts
View does not display Reg Number column
Form Mobile Number label is Cell Phone
Form E-mail label is E-mail

Dependency Tracking - The solutions framework automatically tracks dependencies for solution components. Every operation (such as create, update, and delete) on a solution component automatically calculates any dependencies to other components in the system. The dependency information is used to maintain the integrity of the system and prevent operations that would lead to an inconsistent state.
As a result of dependency tracking the following behaviors are enforced:
  • Deleting a component is prevented if another component in the system depends on it.
  • When you export a solution, CRM will warn you if any dependent components are missing.  
  • Importing solution fails if all required components are not included in the solution and also do not exist in the target system.
  • The dependency framework also checks the state of the component (managed or unmanaged).

Settings area -> Solutions -> Click Solution ->Click Entities - > Check the entity -> Click Show Dependencies

When you add an existing component to a solution, CRM asks if you also want to include any of the component’s dependencies

Exporting Solutions
1. Settings area -> Solutions -> click the solution -> click the Export button. The Export Solution Wizard appears, see all the pictures. Finally it savees the file [Solution Name]_[Version]_[Package Type].zip. Zip contains [Content_Types].xml, Solution.xml, Customizations.xml, (if any files, then folders) WebResources, PluginAssemblies, SolutionAttachments,  Workflows, Reports folder.

Importing Solutions

CRM will accept only valid .zip or .cab files. Solutions downloaded from the marketplace may have a .cab extension. The .cab file essentially wraps the Marketplace information around the standard CRM 2011 solution .zip file.



webdesign india said...

Nice post. Thanks for sharing with us.
crm it solutions

Dynamics CRM Development said...

Thank you for detail explanation with images and reference links. Thank you very much.