Skip to main content

Posts

Showing posts from 2012

Capture and Handle event when one entity record is attached through a Many to Many relationship - MS CRM 4

If you have already dug up too much about trying to capture the event when an entity record in MS CRM is attached ~ linked to a record in many to many relationship. For example, if you have two entities : Supplier and Company in MS CRM where a supplier can do business with many companies and at the same time a Company can order stuff from many suppliers. What if you want to send some notification whenever a new supplier or an existing supplier is linked to a company; similarly you may want to send a notification when a Supplier signs a deal with 2-3 companies and gets linked to those. Some experts from MS CRM fraternity have suggested some ways to over ride this limitation of MS CRM that it does not expose any event for the above mentioned scenario, below is one of the examples:   http://ayazahmad.wordpress.com/2009/07/23/event-on-many-to-many-relationship-nn-in-crm-4/ But making changes to the default plugin model of MS CRM to add Associate or Disassociate event is not so eas

Creating Email through Plugin / SDK in CRM 4 - line breaks don't work

You may have noticed when you create email using a sample code like below in a plugin or for that matter any other SDK based assembley for MS CRM. Your line breaks : \n or \r or System.Environment.NewLine will not work.           email Email = new email();                          Email.to = new activityparty[] { toParty };                      Email.from = new activityparty[] { fromParty };                      Email.regardingobjectid = regardingObject;                      Email.subject = "Hello!!";                      Email.description = "Dear, line 1" +                                System.Environment.NewLine+                          "my message for your - line 2";                      Email.directioncode = new CrmBoolean();                      Email.directioncode.Value = true;                                            Guid _emailId = _service.Create(Email);                                            SendEmailRequest sendEmailReq

Cancel Workflow job programmatically - CRM v.4

How many times you had to created a workflow on some date like Due date which keeps changing as per client's request. While this may sound simple in business, on CRM you have a workflow that may be waiting till this date and send a reminder exactly a week before. So you need to keep calling this workflow every time the date is updated, to make the matters more complicated, all the previous jobs that had initiated due to past modification will keep running and chasing that date which is never going to occur. What you do now, manually cancel those to save system resources and stop the never ending system jobs. There is a way to do it through SDK, in my case I call this function as a custom workflow activity in the first step of the workflow which Cancels any previous jobs of this workflow.   #region Cancel My WFs             QueryExpression qe = new QueryExpression();             qe.EntityName = EntityName.asyncoperation.ToString();             ColumnSet cs = new

MS CRM from Chrome - 2

In continuation with the last post, you can access Microsoft CRM, for that matter IE from Chrome using this link, it's much better and will work with Mozilla and Safari as well I guess http://app.cloudinternetexplorer.com/

MS CRM from Chrome

Open MS CRM in Chrome using this chrome app  With this tiny app you can open and use MS CRM in google Chrome, all you need to do is install this app    https://chrome.google.com/webstore/detail/miedgcmlgpmdagojnnbemlkgidepfjfi Then in new Chrome tab click on the blue IE icon on right side whichi will open site in IE mode from Chrome and then  write your CRM url, enjoy CRM with Chrome, like Browney and Chocolate ! I have also observed though any new  window like a record or customisations views will eventually pop up IE windows but you can still browse the main  page of CRM in Chrome  As you can see below, I have applied some fancy theme to my Chrome to make it more believable that its actually MS CRM in google chrome browser :