Showing posts with label Dynamics CRM Certification. Show all posts
Showing posts with label Dynamics CRM Certification. Show all posts

Monday, July 4, 2011

Microsoft Dynamics CRM 4.0 Whitepapers

Here is a list of some beautiful whitepapers for CRM developers, it always worked as a good reference to me. so thought of sharing it with others too.

you can use them for a reference point or for knowledge building or to understand the product better.

Whitepaper Download

This white paper, details the security model leveraged by Microsoft Dynamics CRM 4.0, including information on the authentication mechanisms that, depending on the deployment model, support Microsoft Dynamics CRM. In addition, the document provides details about how access to Microsoft Dynamics CRM 4.0 system resources by users and external systems can be controlled and restricted.

The Microsoft Dynamics CRM Security Model

This white paper,provides selected aspects of the conceptual application of the security model in Microsoft Dynamics CRM. While Microsoft Dynamics CRM does not provide for true field-level security, there are a number of options available for using supported custom logic to control of access to data at a more granular level than provided out of the box. This document discusses some of the key options and constraints available for implementing this type of solution.

Field-level Security in Microsoft Dynamics CRM: Options and Constraints

Many data centers include firewalls between the end-users and the servers and other integrated systems that support an implementation of Microsoft Dynamics CRM 4.0. This document provides guidance on the connectivity requirements between Microsoft Dynamics CRM 4.0 and other systems to assist readers with proper firewall configuration in customer environments.

Connectivity and Firewall Port Requirements in On-Premise Deployments

Both the online and offline versions of the CRM Outlook Client support synchronizing CRM contacts and CRM activities to Outlook folders, or Outlook synchronization. This document describes the client synchronization process for Microsoft Dynamics CRM 4.0.

Outlook Synchronization in Microsoft Dynamics CRM 4.0

Using multiple instances of Dynamics CRM may be preferable in a number of scenarios. This release includes two documents, a white paper and a build guide, focused on sharing data across multiple CRM organizations. The white paper provides an overview of the levels of integration available for sharing data across multiple Dynamics CRM organizations, together with details about the techniques that are used for integration at the Application and Data levels, which include Web Services, Web Services-based solutions, Filtered Views, and SQL Server Replication.

Sharing Data across Microsoft Dynamics CRM Deploymentsc

Microsoft Dynamics CRM supports a wide range of business applications with the essentials required for building, delivering, and maintaining these applications in a multi-tenant SaaS environment. In this white paper we explore how, with Microsoft Dynamics CRM, an ISV can quickly build, deploy, and manage line-of-business applications.

Developing ISV Applications using Microsoft Dynamics CRM 4.0

This white paper provides techniques, considerations, and best practices for optimizing and maintaining the performance of Microsoft Dynamics CRM 4.0 implementations.

Optimizing and Maintaining Microsoft Dynamics CRM 4.0

These Microsoft Office Visio diagrams show the logical database structure for Microsoft CRM 4.0.

These diagrams were generated using the Metadata Diagram sample code included in the Microsoft Dynamics CRM 4.0 SDK download.

Microsoft Dynamics CRM 4.0 Logical Database Diagrams

Tuesday, June 7, 2011

How To Recreate Users in Microsoft Dynamics CRM

Situation:

One of my teammate recently moved a CRM organization from one server to another server (database as well as the application server), don’t know what went wrong but after that one user complains that he can’t login into the system, when inspected we found that there are two records for the same user now exists in the CRM one disabled and one enabled also no entry of this user was there in MSCRM_CONFIG database.  Still in dark why and how it happens? but in order to let the user in the CRM we need to recreate the user in the CRM.

Resolution:

Now all we need is  to delete this user and recreate it in CRM, BUT BUT BUT…….

There is no supported option of deleting Users from CRM is available , at most you can disable them, but sometimes we found ourselves in a situation when we need to recreate the user in CRM as mentioned above.

we also need to remember that the CRM users are created from AD user accounts so the CRM will not allow you to create a new account even when one account is already disabled.

So what can we do:

The option with us is recreate a User record by changing the credentials of a user record and create a new record for the existing user.

we can do so by following the steps as mentioned below:

Step 1: navigate and open the desired User record in CRM.

Step 2: Change the user credentials in the Domain Logon Name field to and AD use record that is not already a CRM User and save the record.

Step 3: Since this record is not required in CRM at all so disable this record.

Step 4: Create the desired user record.

Step 5: Reassign the records of the disabled user to this newly recreated record.

Tuesday, August 25, 2009

Changing Ownership of Accounts changes ownership of others too

When we reassign a CRM Record then by default, Dynamics CRM reassigns all child records too. This behavior has consequences you might not want, such as reassigning paid invoices and other closed transaction records too, or think about a scene where two different sales reps are working on two different opportunities, associated with the same account then if the ownership of account changes the CRM reassigns the ownership of these two Opportunities too to the new owner, not only that the reassignment is done irrespective of the status of the related child record. i.e even the closed sales too goes in account of the new owner.

In short Selecting a different value for the “Owner” field (reassigning of the record) would reassign the account to the newly selected CRM user. Along with a lot of other records, which is the potential problem when historical sales reports are needed.

for quite some time i was thinking about the issue and the possible solution. Today I got a surprise visitor in my outlook (the RSS feed from dynamicscrmtrickbag). much to my surprise Richard Knudson explained the same issue and the solution in his blog.

The solution was quite simple :

Have a look at all of the 1:N relationships the Account entity has with other
Dynamics CRM entities , change the Type of Behavior of the required relationship
from default “Parental” relationship to “Configurable Cascading” and change the
assignment behaviour by changing the "Assign" value to the desired behaviour
(Cascade Active or Cascade None or Cascade User-Owned).

I would recommand the reading of full article here.

Great piece of artwork Richard. Cheers.

Monday, June 15, 2009

Create Custom Workflow Activities for Microsoft Dynamics CRM 4.0

Sometimes there are situations when we need to add our own custom logic in workflow. The answer to it is custom workflow activity in Microsoft Dynamics CRM 4.0.

keeping that in mind I have decided to write a post for the same, but as usual before writing any new post I searched for the same on some of my favourite blogs and then I found a great article on the same on stunnware.

A must read post for all newbies. You can find it here.

happy coding :-)

Thursday, June 11, 2009

Invalid Argument error when importing customization

If you export an entity before it has been published, you will get an 'Invalid Argument' error when importing the entity if it has any relationships.

The reason for this is that the relationship attribute will have no display name, which results in the error. The simplest solution would be to go back to the original deployment, publish the entity, then export again. But, if that's not an option, you can fix the problem within the exported xml as follows:

The invalid relationship xml will look like the following:





The problem is that the displaynames element is blank. This can be changed to something like the following





The languagecode attribute will need to be set to the correct value for your deployment. Many other elements will have this value set in the customizations.xml file

Wednesday, June 10, 2009

"Not have enough privilege to complete Create operation for an Sdk entity" exception while registering a CRM 4.0 plug-in

when you try to deploy new plug-in assembly into CRM 4.0 and instead of successfully deploying you get the strange looking Soap Exception "Not have enough privilege to complete Create operation for an Sdk entity".

Unhandled Exception: System.Web.Services.Protocols.SoapException: Server was unable to process request.
Detail:




0x80040256
Not have enough privilege to complete Create operation for an Sdk entity.
Platform




It looked pretty strange because your user might be having System Administrator role and in CRM it might be having all the rights.

Note: The Active Directory account used to deploy and register new assembly into CRM 4.0 database has to be added into Deployment Administrators group in CRM Deployment Manager.

Here are the steps to accomplish this:

1. Open CRM 4.0 Deployment Manager Console (Start -> All Programs -> Microsoft Dynamics CRM -> Deployment Manager).

2. Go to “Deployment Administrators” node and choose “New Deployment Administrator…” option.

3. Insert appropriate user and confirm selection by clicking “OK” button.

After completing this step, your users will be able to register and deploy the assembly successfully. So, remember about this when you try to deploy plug-ins with user that you added to CRM.
Happy Coding :-)

wish to change the code after plugin is deployed ?

After registering your plugin if you wish to change the code, you might get a build error when building the solution again in Visual Studio:
something like :
Unable to copy file "obj\debug\MyPlugin.dll" to "..\..\..\..\Program Files\Microsoft Dynamics CRM Server\Server\bin\assembly\MyPlugin.dll". the process can not access the file "..\..\..\..\Program Files\Microsoft Dynamics CRM Server\Server\bin\assembly\MyPlugin.dll". because it is being used by another process.
This occurs because Microsoft CRM has a lock on the DLL. In order to release the lock, you have to restart the service that has it locked.

For synchronous plug-ins, the CRM Application Pool within IIS can be recycled, or you can run IISReset.

For asynchronous plug-ins and custom workflow assemblies, you have to restart the Microsoft CRM Asynchronous Processing Service in the Services Control panel Applet.

To recycle the CRM Application Pool from the command line: Click Start, Run, type “cscript c:\windows\system32\iisapp.vbs /a CRMAppPool /r” and press enter.

To restart the Microsoft CRM Asynchronous Processing Service from the command line: Click Start, Run, type “net stop mscrmasyncservice” and press enter. Click start, Run, type “net start mscrmasyncservice” and press enter.

Thursday, May 28, 2009

Share Records programmatically

Few days back our client placed a new requirement that he needs the newly created lead needs to to be shared by all the team mates of the businessunit, and that needs to be done automatically. I thought a workflow on lead creation will do the job. But when I sit on the system and to my surprise found that there is no option in the workflow manager for the same. I started scratching my head and at last decided to write a plugin for the same. Now instead of writing everything from scratch I asked the same to my good old friend (GOOGLE) :-) and i was really surprised to get this post by David Fronk of Dynamic Methods Inc. He explained everything in such detail that ...... it starts looking like a kid's play.

With all credit to his great job the excerpts of the post is :

Most implementations just open things up at the business unit level, or even the global level (depending on the size of the company) and don't even worry about sharing. However, there are times when certain information can be sensitive and necessary to restrict access to. Typically these things can be activities, opportunities, cases, services billed, hours worked, etc.


For instance, suppose sales reps aren't allowed to see support cases but are allowed to see the accounts that they manage. Any good account manager would want to know what support issues their account has been having before engaging on a new business proposal, so obviously the sales rep should get to see the cases related to the account.


All that is required is a couple of plugins at two main points and upon creation of a case and reassignment of an account. Whenever a case is created, get the account manager of the account on the case and share the case with that user. If the account gets reassigned, remove the share from the old account manager and add rights to the new account manager. Now with simple logic you can make data more accessible to those who should see the data without them having to do anything more than their regular job.


One side note, be aware that the more items there are under a parent record the longer the reassignments of records will take. For instance, if I reassign an account with 50 cases that's going to take a lot longer to complete the reassignment than it would if there were 5 cases, or even none. Just keep that in mind as you develop your sharing solution.


Pretty simple, and the SDK has some great examples on how to do this. Look up "AccessRights Enumeration", "GrantAccess Message", and "RevokeAccess Message" in the SDK and you should have everything you need.


Here's a quick example on how to share and give all rights to a user:





SecurityPrincipal principal = new
SecurityPrincipal();
principal.Type = SecurityPrincipalType.User;
principal.PrincipalId = new
Guid("7B222F98-F48A-4AED-9D09-77A19CB6EE82");
PrincipalAccess access = new
PrincipalAccess();
access.Principal = principal;
access.AccessMask = AccessRights.ReadAccess;

TargetOwnedDynamic target = new
TargetOwnedDynamic();
target.EntityId = new
Guid("6A92D3AE-A9C9-4E44-9FA6-F3D5643753C1");
target.EntityName = "incident";

GrantAccessRequest readGrant = new
GrantAccessRequest();
readGrant.PrincipalAccess = access;
readGrant.Target = target;
GrantAccessResponse readGranted = (GrantAccessResponse)crmService.Execute(readGrant);

access.AccessMask = AccessRights.WriteAccess;
readGrant.PrincipalAccess = access;
GrantAccessResponse writeGranted = (GrantAccessResponse)crmService.Execute(readGrant);

access.AccessMask = AccessRights.AppendAccess;
readGrant.PrincipalAccess = access;
GrantAccessResponse appendGranted = (GrantAccessResponse)crmService.Execute(readGrant);

access.AccessMask = AccessRights.AppendToAccess;
readGrant.PrincipalAccess = access;
GrantAccessResponse appendToGranted = (GrantAccessResponse)crmService.Execute(readGrant);

access.AccessMask = AccessRights.AssignAccess;
readGrant.PrincipalAccess = access;
GrantAccessResponse assignGranted = (GrantAccessResponse)crmService.Execute(readGrant);

access.AccessMask = AccessRights.DeleteAccess;
readGrant.PrincipalAccess = access;
GrantAccessResponse deleteGranted = (GrantAccessResponse)crmService.Execute(readGrant);



And here is an example on how to revoke access:





SecurityPrincipal principal = new
SecurityPrincipal();
principal.Type = SecurityPrincipalType.User;
principal.PrincipalId = new
Guid("7B222F98-F48A-4AED-9D09-77A19CB6EE82");
PrincipalAccess access = new
PrincipalAccess();
access.Principal = principal;
access.AccessMask = AccessRights.ReadAccess;

TargetOwnedDynamic target = new
TargetOwnedDynamic();
target.EntityId = new
Guid("6A92D3AE-A9C9-4E44-9FA6-F3D5643753C1");
target.EntityName = "incident";
GrantAccessRequest readGrant = new
GrantAccessRequest();
readGrant.PrincipalAccess = access;
readGrant.Target = target;
GrantAccessResponse readGranted = (GrantAccessResponse)crmService.Execute(readGrant);

CRM 4 Certification Practice Tests

Hi all,

Richard recently authored practice test questions for the three core CRM 4 certification exams. he is having LOTS of other articles on the exams and how to prepare for them in the certification category. So if you are thinking of clearing the MB 631 , MB 632 or MB 633 you must visit this place.

you can test your knowledge with these practice test here

i have gone through the tests and it is really great. try your knowledge there and best of luck :-)