Monday, August 6, 2012

Tips to Install CCA for CRM 2011

The Customer Care Accelerator for Microsoft Dynamics CRM 2011 delivers contacts center functionality. The CCA for Microsoft Dynamics CRM will work with all deployment models for including on-premise and Microsoft Dynamics CRM Online.

You can follow below Steps to Install CCA:

1.       To install CCA you need to download the setup from Microsoft Marketplace. The installation package contains source code, binaries, customizations, and documentation.
2.       Unzip the downloaded file. It contains an Accelerator folder (CCA setup files) and a UII folder (the UII framework install files). You also get a couple deployment guides.

3.       From the UII folder run the executable file (32 bit or 64 bit). It is a simple installation process. While installing you will be asked to specify the organisation name where you intend install CCA. Please refer below screen. Specify the Organization Name and proceed with complete package install to use all features of CCA.


 4.       Now from the Accelerator folder run the 32 or 64 bit executable file. This will unzip few more files into the install folder. After this run, the “Microsoft UII” folder will contain all the source code and other files which are required to proceed with the further steps.
5.       In next step you need to import some solution files in CRM. Import the two solution files listed in below screen shot:
           a)      Import the solution “UiiForMicrosoftDynamicsCRM2011_1_0_managed.zip” from the location specified below:


b)      Import another solution “ReferenceImplementationforUII_1_0_managed.zip” from the location specified below.

 
  6)       After importing the above managed solution you need import below specified data files which you need to map with “UII Hosted Applications” entity as shown in below screen.
(Note: Please make sure that you have installed standard Sample Data in your CRM. Go to Settings -> Data Management -> Sample Data and install sample data into your system)

 

 While Importing these files you need to fix the 2 field mapping errors before you process the files which are listed below:


 Map the Above fields to their associated field and proceed with import.
7)      Next Step is to generate “RIConfigLoader” application. For this you need to follow the instructions from the UII Deployment Guide to Install UII Component.
8)      Open the “Microsoft.Crm.Accelerator.Cca.AgentDesktop.sln” solution file and build the solution.


To resolve this issue you need to download the “Microsoft.Practices.CompositeUI.Windows.dll”, add reference to the project and build the solution. This will generate the “RIConfigLoader“ application. Run the application shown in below screen shot.



9)      Once you run this, you will get the below screen to connect with CRM.


Provide the connection details required to connect to CRM. To get the CRM Service URL Go to Settings -> Customizations -> Developers Resources. Look for the Discovery Service URL. When the connection is successful you need to select CRM Organization and click on “Deploy” as shown in below screen.


10)      Go to the location where Agent Desktop’s “config” file is located and open it in Notepad. We only need to change the Organization Service URL and Authentication Mode in the “AgentDesktop.exe.config” file as shown in below screen shot.


11)      Run the Agent Desktop Application.



12)      You will get the pop up of CCA Agent Desktop screen as below.


13)      When you click the Case it will automatically navigate to the Customer i.e. Account page. You can also find the Task explorer where you can select workflow list from which you can initiate a CCA workflow as shown in below screen shot.


14)      When you select “Service Case By Phone” and follow the steps you will get the below screen to Dial a Number on the step of Call Customer.


15)      After this you can add your notes in the Text Box to update Notes in the Selected Case. Please see below screen shot.


Sunday, July 29, 2012

How to get all the selected records id for the bulk edit form

Further to one of our previous blog spot

We can write scripts on bulk edit form to check that the entered field value is unique for the selected group of records. If the value is duplicate then the user should get an alert and the bulk edit form should be closed.

To achieve this, we need to retrieve all the records and compare the new value with the existing values.

But to retrieve we require the ids of all the selected records for bulk edit. To get ID we normally use

Xrm.Page.data.entity.getId()

But this will not give us the id of all the selected records. To get ids of all selected records we need to use a window command window.dialogArguments.

 //check whether the form is bulk edit form

 var formType = Xrm.Page.ui.getFormType();

if (formType == 6)
{

 //Read ids from dialog arguments

 var records = window.dialogArguments;

 for(i=0; i<records.lenght;i++)
 {
   alert(records[i]);
 }
}

Hope this helps and is useful!!

Friday, July 20, 2012

Outlook Authentication issue fixed in Rollup 8

We have noticed this with the Online and IFD environment, that, if you are using "CRM 2011 Outlook Client" and try to open any web resource like html file and Silverlight application (.xap file) or any entity record using window.Open() or Response.Redirect() then you get prompt for user name and password.

Window.Open() methods opens the CRM record in the browser (IE) and outlook does not pass your CRM credential. As you are not logged-in in the CRM from browser (IE), it asks credentials of user.

If you are already logged-in from browser and open CRM record from Outlook client then it will not prompt for the user credential.

Microsoft has released Rollup 8 which exposes two new methods through SDK. These methods will open window in the process Outlook.exe instead of Iexplore.exe. So it will not ask for credentials.

Below are two methods:
 
     1)  openWebResource(string webResourceName, string webResourceData, int width, int height):

This opens a HTML web resource page.

             i.   webResourceName: This is the name of the web resource that you want to open.
             ii.  webResourceData: Parameter that is to passed to the web resource. Web page (HTML) or Silverlight Web resource page can only accept a single custom parameter called data.
              iii. width: Width of the window
              iv.  height: Height of the window.
 e.g. Xrm.Utility.openWebResource("new_/pages/test.html",null,700,700);
 
 
     2)  openEntityForm(string name, string id, Dictionary parameters):
This opens an entity form dialog e.g. Account record.
 
                  i.            name: Name of the entity of which record is to be opened. e.g. account.
                  ii.           id: GUID of the record. e.g. "89A2F3FB-18FF-E011-A003-00155D005515".
                  iii.          parameters: Parameter that is to passed to the record. 
e.g. Xrm.Utility.openEntityForm("account","89A2F3FB-18FF-E011-A003-00155D005515",null)

Tuesday, July 17, 2012

Quick Tip - Allow Lookup fields to search by multiple attributes

Lookups as you know in CRM show a list of records of a related entity. Using the lookup, you can search for records by typing in the search key words to filter the list.

This search is performed on all fields that is listed in the Find columns in the Quick Find View of the entity.

Instead of clicking the lookup button, the same search can be performed by directly typing in the search string in the lookup field.

The Lookup field is designed to auto-resolve the text to a matching record in the lookup entity.

This little known feature is very helpful in cases, where you identify the records not by thier names but by a unique id. Take for example you have a form in CRM that you need a user to fill in, and the user is aware of the SSN # of the contact and it would be a time saver if the user could type in the SSN# in the Contact lookup and it would auto-resolve to the Contact.

To acheive this follow the steps below

1. Customize the Contact entity
2. In Views, Select Quick Find View


3. Click on the Add Find Columns

4. Check the SSN field


5. Save and publish the entity.

Open the Account form. In the Primary contact type in the SSN# and tab out...



It will auto resolve to the contact that has that SSN# assigned.


Hope this little trick saves a lot of data entry time!

Monday, July 9, 2012

R8 aka Q2 2012 Service Update Plans revised

The Q2 Service Update plans have been revised. As per the road map made available earlier this year, Q2 Service update was all about "CRM Anywhere". It planned to include Cross Browser availability and Mobility that would let Dynamics CRM be accessible "anywhere" be it any browser or any device.

However in the recent Press Release posted on 6th July, Cross Browser availability and Mobility plans have been delayed and these would not be included in the Q2 update. Here is what it says

On July 19th, as we committed, our Q2 release will include Microsoft SQL Server 2012 support, Industry templates and certifications for our online service. After listening to the feedback from our customers and partners we are delaying availability of Microsoft Dynamics CRM Mobile and cross-browser support. These were previously scheduled to be delivered in the Q2 2012 Service Update, and we now plan to deliver them in the service update scheduled for Q4 2012


You can read the entire post here

This was one of the features that I was most excited about and I am little disappointed with the delay... Q4,,, a bit too long a wait :( Nonetheless it is always better to have a great finished product than half-baked one and as long as this feature is made available in the future with no scope for issues/errors.... I would be willing to wait...

Waiting for a great Cross-Browser Release!!!

Tuesday, June 19, 2012

CRM 2011 Install Errors - Tips and Tricks continued

The more I get to install/upgrade to CRM 2011 in different environment the more I come across different issues and fortunately there are workarounds to it. So here are some additional items found since the last post on this subject.

A Microsoft Dynamics CRM Server component is using the same account as the instance of SQL Server Reporting Services

You receive the above error when installing SSRS Data connector. I had never seen this before. But this was a system on which there was a previous install of CRM 2011 Async service (A distributed install). The Reporting Service was running under Network Service Account. Changing it to another domain user account did not fix this issue.

This issue has been explained in detail in this KB article http://support.microsoft.com/kb/974584. Though this KB has been targetted for CRM 4, the following section of the resolution worked in this particular case

Add the IgnoreChecks registry key to the computer that is running Microsoft Dynamics CRM so the installation can proceed when an error is shown in the Environmental Diagnostic Wizard (EDW):
  1. Click Start, click Run, type regedit, and then click OK.
  2. In the registry, locate the following subkey:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM
  3. Right-click MSCRM, point to New, click DWORD Value, and then type IgnoreChecks.
  4. Double-click IgnoreChecks, and then type 1 in the Value data field.
After this change is made, the Environmental Diagnostic Wizard will still point the same error. But notice the Next button is now enabled :) Go ahead click Next and complete the install.

After successful installation remove the key added to the registry.

Index was outside the bounds of the array.

I came across this while trying to fix the one above :) The one above complained about same service account being used, so I tried to fix it by using a Domain user account. Instead of typing the user name, I chose to use the lookup button to seach the user from the AD. Selecting the user set the service user name in the form of user@domain.com.

Change the service account back to domain\user and this error will vanish.

Action Microsoft.Crm.Setup.Server.GrantConfigDBDatabaseAction failed.
Windows NT user or group 'NTDomain\SQLAccessGroup{xxx} not found.

If you see this error during an install or upgrade and if you are using SQL Server on another machine, you are connected to the SQL Server machine through an RDP session. Log off. Restart the install and it will proceed without any error :)

The transaction log for database 'ORG_MSCRM' is full due to 'ACTIVE_TRANSACTION'.

Do not try to check the transaction log size for this. Most probably all is good there. The first thing to check is free disk space on the drive on which the ORG_MSCRM database and log file resides. You are probably running out of space there. Make some space and you are ready to go. Check this

Installation of Microsoft Visual C++ Runtime failed. Exit code: 5100. Result: Asia

Setup will not run on a machine that has Visual C++ 2010 with version 10.0.40219 install. This system had SQL 2012 installed that probably installed this higher version. CRM Setup requires an older version to continue. Go ahead and uninstall the VC++ redistributable on this machine and let CRM install the required components including Visual C++

As usual, the above solutions have worked in our scenario and you can give them a try at your own risk

Monday, June 11, 2012

How to Debug Plugins using Profiler



One can debug CRM plug ins without connecting to CRM server or without remote debugging.

Here are the steps as in how you can use Profiler for debugging plug ins:
   1>     Connect to CRM using plugin registration tool of March SDK 2012.

   2>      Click on Install Profiler
         

   3>     You will find a new node attached to registered plugins “Plugin Profiler”.






   4>     Select a plug-in step and click Profile to enable profiling.



5>     Then start your plugin from MSCRM i.e if your plugin is on update perform  update operation and download the error file.
6>     Then in Visual Studio attach to process “plugin registeration.exe”. Add the breakpoint  from where you would like to debug.



7>     Then click on Debug in plugin registration tool.


8>     In Profile location provide the path of the error log of the plugin.

9>     In Assembly location provide the dll of the plugin from which you got error.

10>     Then select the Plugin class from Plug-in. This drop down will contains all classes present in the dll.

11>     To start debugging just click on Start Plug-in Execution.

      

Saturday, May 26, 2012

Solutions to issues with Reports in Dynamics CRM 2011

OK I am having a real hard time getting reports to work after installing CRM in recent times. This is an attempt to compile all SQL reports related errors and solutions that have worked for community in general. I have not checked each of the solutions but since I am experiencing issues with reports pretty often I am create this as a quick reference source. The solutions and errors have been picked up from queries posted on community forums and other blog posts.

1. Reports dont work after upgrade to CRM 2011 not even in the new organization added.

I have a separate post on that. But if that does not resolve your problem. It could be that the CRM 4 reports are still being referenced and the new CRM 2011 reports are not being published. The reports do not work in any of the CRM organizations. The Reports are stored in Shared Reports\5.0 folder on Report Server. You can go ahead and delete the Shared Reports folder and then execute the publishreports.exe to publish the reports.

2. Reports do not work with the following error recorded in the log files.

You can access the log files at Program Files\Microsoft SQL Server\MSRS10_50.MSSQLSERVER\Reporting Services\LogFiles

Cannot create a connection to data source 'CRM'. ---> Microsoft.Crm.Reporting.DataExtensionShim.Common.ReportExecutionException: Immediate caller DOMAIN\crm has insufficient privilege to run report as user S-1-5-21-1756635634-....

There are a couple of solutions available for this.

Open Reporting Services Configuration Manager and uncheck the credentials provided in the Execution Account


Another solution available on this blog.

3. Another common reason for reports not working is the user running the reports is not a part of the following groups






4. Check your Datasource settings in SSRS.

There are 2 datasource created within each CRM organization as well in the Shared Reports folder.

MSCRM_FetchDataSource - This is used by Fetch based Reports

MSCRM_DataSource - This is used by SQL queries based Reports


This is not a comprehensive list and suggestions to include other problems/solutions related to reports in this post are most welcome.

Note: These solutions should be used at your own risk.

Wednesday, May 16, 2012

Reports Not Working After Upgrade to CRM 2011

I have worked on various upgrades and none have really had issues with the reports not working. I make sure that the SRS Data Connector is installed without fail. 


When you install CRM with the SQL server being separate from the CRM server, the setup does not automatically prompt you to install Reporting Services Extensions. You need to manually copy the  SrsDataConnector folder found in the CRM install directory to your SQL server. Run SetupSRSDataConnector.exe from there. This will prompt you to select the SQL server and the Reporting Server instance and go ahead and install all the reports for you.


In my case this was already done and yet the Sub-Reports did not work. The main reports would work but the moment we clicked on Show More Details that would require the sub-report to be executed, it would throw an error "Details could not be displayed as the sub-report could not be found". The Event viewer recorded the following error


Report render failure. Error: The item '/SharedReports/5.0.xxxx/{6177ee54-f42e-e011-a793-001ec9bbc670}' cannot be found. (rsItemNotFound)


Checking the Report Server using http://server/Reports showed that though the sub-report was present in that folder it had a different Guid than the one shown in the event viewer.


Since this was an upgrade, I thought it might still be using CRM 4 Guids and publishing the reports again would probably fix the issue. I found "PublishReports.exe" in the tools folder of CRM Installation directory. 


Executed that exe from command prompt using publishreports.exe uniqueorgname


It showed that it published some reports but that did not resolve my problem :(


I then came across this post that helped me reset the setting in MSCRM_Config database .


There is a setting in MSCRM_Config --> Organization table "AreReportsPublished". You need to set the value of this attribute to 0/False. This will be get the PublishReports to publish the reports once again.


After making this change, executing the PublishReports.exe tool helped in get my reports working again!


No matter how many upgrades you work on.... each one is a different case :)

Sunday, May 13, 2012

UR8 released and UR9 "Beta" now available!

UR8 for Dynamics CRM 2011 was released a couple of weeks back. Note UR8 does not include the Cross-Browser and other features. UR8 is only a release of patches to the existing CRM 2011 application that includes hotfixes.

You can download UR8 from http://support.microsoft.com/kb/2600644

Within a few weeks from the release of UR8, UR9 has been made available for public beta. You can check Girish Raja article for more details on how to subscribe to the beta. Go get your beta copy right now!

Tuesday, March 27, 2012

Read Optimized Form made available through UR7

After installing UR7, there are chances you may not find any changes with respect to the much talked about Read Optimized form. That is because the default setting for RO is switched off and by default all forms are expected to open in Edit mode.


You need to make the change at Organization level using the Settings Dialog.







You can either have the forms open by default in Read Optimized (RO) mode or Edit mode. If you choose RO, all forms for all users would open in RO unless individual users have overridden the default to set their own preferences using the individual options available to each user.





Note if you uncheck the Allow users to select a mode for viewing forms, you can force the users to follow the organization level setting enforced by the administrator. The above option will then not be available on individual user settings form.




The individual user settings always take preference over Organization settings.


So what is a Read-Optimized form?
This form will display the record in read-only mode this means that user will not be able to edit the details on the form. The idea behind this being, most often users access existing records for viewing the details rather than editing them.


The benefit of RO form is that it loads much faster than an Edit form. It is much like the Print Preview Option that was always present in CRM. When you did a print preview it would show up a window with all the details laid out just as it is on the form.

The trade-off however has been that it would now not include or support the following
1. Left navigation links missing
2. Ribbon Missing
3. Web Resources cannot be included on the form, if included the form will not open in RO even if user preference is set to RO form for viewing.
4. If you have scripts included on the Onload event then again the forms would not open in RO view until the scripts are removed from the onload event handler.

Here is what the url now looks for Read Optimized Form. A new flag &rof has been provided that lets you provide the RO setting. True would open the form in RO view if it is possible i.e it does not include scripts or web resources that prevent the form from opening in RO view.

http://crm5:5555/orgname/main.aspx?etn=account&pagetype=entityrecord&id=%7b78D41C71-C62F-E111-974F-00155D000F03%7d&rof=true

The above link would open the account form in RO mode even if the users individual setting was set to Edit mode.

If the &rof flag is not included in the URL then it will open based on the default View settings for the user.

What if you would want to check the activities that were earlier available in left nav links on the form? Add them as a sub-grid on your form and the RO view would list them out



You can open the activities to view the details and then these would also open in RO mode. But you are not allowed to create new activities. The buttons are missing.

If you notice the notes pane, it lists the notes but you cannot download the attachments or add new notes.

If you had Webresources that you wanted to include on the form even in RO mode? You include that instead as an IFRAME. In the example below... we have picked up the web resource URL and copied that in the IFRAME.


The URL to the Webresource should include the Organization name if you are providing relative url.
/orgname/WebResources/new_/Maps.html

You can design multiple role based forms in CRM and the Read-Optimized mode will apply to all of the forms defined. If a user has access to more than one forms, just like before it would by default open the last viewed form by the user in RO view.

There might be probably more that comes up once we start looking into this deeper and we will make sure to come back and update this based on the new understanding of the RO concept...

Friday, March 23, 2012

IFD Configuration

While setting up IFD, we had issues in enabling the claims for CRM 2011. After trying to enable claims for CRM 2011 through Microsoft Dynamics CRM 2011 Deployment Manager when we trid to browse the URL: https://XYZ.com/FederationMetadata/2007-06/FederationMetadata.xml we were getting one of the following errors:

- HTTP 503 Service Unavailable error.
- HTTP 404 Not Found error.

When "FederationMetadata/2007-06/FederationMetadata.xml" is requested through the browser CRM website, it has the rule that rewrites the URL to handlers/Federation Metadata.ashx. So when one gets such types of error then it means IIS URL Rewrite module is not rewriting the URL correctly.

The solution for this issue is to re install the IIS URL Rewrite.

If the reinstallation of IIS URL Rewrite does not resolve the issue. The Issue could be due to Reserved URL. To find the Reserved URL follow the below given steps.

a) Open Command Prompt.
b) Type the Command NETSH HTTP SHOW URLACL.
c) This command will show all the reserved URL's.
d) If you get any reserved URL with error as given below.

Reserved URL : https://ABC:443/
Can't lookup sid, Error: 1332
SDDL: D:(A;;GA;;;S-1-5-80-2246541699-21809830-3603976364-117610243- 975697593)

e) Then we have to delete each URL for which we get such type of error as given above using the below command. Please provide the full URL for which you get the error in the command Prompt.

netsh http delete urlacl url=https://ABC:443/

f) After that again run the command to check if the reserved URL is still having an error message through command NETSH HTTP SHOW URLACL.

g) Repeat the step (e) for each URL for which you are getting the error.

h) After deleting all the Reserved URL through the Command,do IIS RESET on CRM server.

i) Configure CLAIMS again using Deployment Manager on CRM 2011.

j) Now try to access the federation Url “FederationMetadata/2007-06/FederationMetadata.xml"again.

We have refereed the blog http://blogs.msdn.com/b/emeadcrmsupport/archive/2011/05/13/we-receive-http-errors-while-accessing-the-crm-federationmetadata-url.aspx to resolve the issue.

The above listed steps should resolve the issue.

Tuesday, March 13, 2012

N:N association

When we have to associate the records we normally use AssociateRequest but while associating campaign with campaign related items such as Campaign, Marketing List, Product, or Salesliterature it doesn’t work.

For achieving this we have special Message made for Campaign called AddItemCampaignRequest.
Below we have provided the code that will associate the Campaign with Campaign Items.

//Add Item to Campaign
AddItemCampaignRequest req = new AddItemCampaignRequest();

// Specify the Campaign Id
req.CampaignId = new Guid(CampaignId)

// Specify the Logical name of the entity to which we want the Campaign to be associated
req.EntityName = entity.LogicalName;

// Specify the Id of the entity to which we want Campaign to be associated
req.EntityId = new Guid(EntityId)

// Execute the request
AddItemCampaignResponse resp = (AddItemCampaignResponse)_service.Execute(req);

We can associate Campaign, Marketing List, Product,
or Salesliterature with the Campaign through the AddItemCampaignRequest message.

To use this message, pass an instance of the AddItemCampaignRequest class as the request parameter in the Execute method. To perform this action, the caller must have access rights on the campaign entity instance.

Same we can associate the Campaign Activities with the Marketing Lists through the AddItemCampaignActivityRequest as given in the below code.

// Create the request object.
AddItemCampaignActivityRequest add = new AddItemCampaignActivityRequest();

// Set the properties of the request object.
add.CampaignActivityId = new Guid(CampaignActivityId);

// Specify the List Id to which we want Campaign Activity to be associated
add.ItemId = new Guid(listId);

// Specify the Logical name of the entity to which we want the Campaign Activity to be associated
add.EntityName = EntityName.list;

// Execute the request.
AddItemCampaignActivityResponse added = (AddItemCampaignActivityResponse) service.Execute(add);

The Marketing List being added must have already been added to the campaign otherwise error will be thrown and Marketing List will not be associated with Campaign Activities.

Hope this helps!!!

Monday, March 5, 2012

Experiences from the MVP Summit!

Well, this was one travel that I had not planned for. But today I am happy that I did not skip it. This was my first MVP summit after being awarded MVP in January this year and it was an enriching experience.

I was one of the 41 CRM MVPeeps that were present at the summit and I was the only one from India in the CRM Group. The group had representation from most parts of the world and it was great to see the reach and adoption of CRM across the world.

There were many sessions revolving in and around CRM and unfortunately not much can be shared here to due to the NDA. All that can be said though is CRM is heading the right direction and we are in safe hands :)

It was a pleasure to hear the product team speak about the future of the product and thier vision for the product. It was good to know we could share our concerns and they would be addressed and that we were not just there to hear them talk but the product team was listening to us as well and that as MVP we were really a valuable community for them.

Amy did a really great job at organizing the sessions and many thanks to her to make sure we are all well looked after :)

Besides the sessions which were by the way not all work but actually a lot of fun, there were also other parties organized in the evenings. The closing ceremony was held at Centurylink fields. There was a fireworks show and we had a chance at the ball on the fields.

A very big thanks to all MVP's to make us first timers feel welcome. Looking forward to Convergence that starts 18th March and I expect that to be an equally enriching experience and I really look forward to meeting all my friends back again!



Tuesday, February 28, 2012

Issue with plug-in in CRM 2011

We had a requirement to do some calculation and update self record of custom entity. We have created a plug-in and registered it on post operation of update event. The code was reading the post image, updating some fields and updating the same.

The plug-in was working fine for single record. But when two records are saved simultaneously, the plug-in was giving below errors randomly.


1. "ValidateOpen - Encountered disposed CrmDbConnection when it should not be disposed"
2. "You cannot create a SqlExecutionContext from another SqlExecutionContext on which OnBeginRequest has not been called"
3. " System.InvalidOperationException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #58919D7E"
4. "System.NullReferenceException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #1638FFA8"

When we checked in the Event viewer then we got that whatever error we get from CRM the Event viewer shows "System.InvalidOperationException: There is already an open DataReader associated with this Command which must be closed first." error.

After searching on net we found that CRM does not re-initialize the plug-in object again, it uses the same object. In the plug-in, ignore to use class level variables. We had created service object at class level so it was using the same service object for retrieving and updating.

Also we were reading post image and updating the post image as it is. This was also creating a problem. Please create a new object of Entity and then set only those fields which you want to update. Then update the record.

Sometimes this plug-in takes too much time as it was doing so many calculation. We were getting the "Query execution time of 30.1 seconds exceeded the threshold of 10 seconds. Thread: 4; Database: inogic_MSCRM " error when plug-in takes time. To resolve this, please add below keys in the registry on CRM server.
1) HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM\OLEDBTimeout
a. In seconds
b. The OLEDBTimeout value controls the SQL time-out value that is used for a single SQL query
c. Set it to 60 seconds


2) HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM\ExtendedTimeout
a. In milliseconds
b. The ExtendedTimeout value controls the ASP.NET time-out value
c. Set it to 1,000,000


3) HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM\NormalTimeout
a. In milliseconds
b. Specifies the SOAP call timeout for most operations
c. Set it to 300,000

Hope this helps!!