Saturday 13 June 2015

Social Pane control not working in custom forms. (activities and post not appear)

Sometimes when we add custom form to our entity, the social pane (Notes) just appear with notes tab without post and activities tabs.

like this image:

basic_notes_control

and whatever you change the default tabs, it's still not appeared:

notes_control_properties 
so after research the solution is exporting the form as part of an unmanaged solution, extract the contents then edit the Customization.xml file by finding the FormXml of the form you wish to view social pane.( //FormXml/forms/systemform/FormPresentation)

 You’ll need to switch the following attribute(FormPresentation) from “0” to “1”. After that, save the file, rezip and reimport the solution. Publish and you’re good to go.


Friday 12 June 2015

When the CRMapppool automatically stopped in IIS

hello,

Sometime the CRMapppool automatically stopped in IIS.

You have to make sure that app pool is set to a service account, the main reason you use a service account is because you don’t need to reset the password every 60 days.

 Sometimes this setting won’t have been set and the app pool password will change and until someone goes in and puts/resets the password the CRM App pool will stop working.

 When the CRM app pool stops working, CRM stops working..

and there is some setting to be done:

Changed the following settings in CRMApppool:

1. CRMApppool ->Advanced Settings -> Start Mode -> Always Running.
2. MS CRM Application -> Advance Settings -> Preload Enable -> True.

Thursday 11 June 2015

Validating (Length and [is numeric] ) Phone Numbers in CRM 2013

hello,
to make sure that your phone field is just contains numbers with fixed length  see this function:
in this example we set the max lenght is 10:

function validatePhone(context)
{

var phone =context.getEventSource().getValue();
var sTmp = phone.replace(/[^0-9]/g, "");
phoneRegex = /^\d{10}$/;

if( !sTmp.match( phoneRegex ) )
   {
   event.returnValue = false;
   alert("Phone must contain 10 numbers.") ;
   }
else
  {
   var sTmpClean =  "(" + sTmp.substr(0, 3) + ") " + sTmp.substr(3, 3) + "-" + sTmp.substr(6, 4);
   context.getEventSource().setValue(sTmpClean);
  }
}

Insert / Add Graphics to CRM Email Template

There is no direct way in crm to add image to email template body, but we can achieve this by doing below steps:
  1. Create a special page on your website that contains all the graphics that you would like to include in CRM e-mails template body message.
  2. Display a page in any browser.
  3. Right-click on the graphic that you want to insert in your e-mail and choose the “copy” option.
  4. Position the cursor in your CRM e-mail template body message to where you’d like to place the graphics and paste it.
  5. The graphic will now appear in your e-mail template body message.
i hope that help.

Tuesday 2 June 2015

Get all Pending or Failed Emails

hello,

if anyone want to see all pending or failed emails for my contacts in the system, it's very easy.

We have to create Advanced Find Query to List all (Contact , Email Address) that in the list of attempted sending Email, but still Failed or Pending.

We have a relationship  called Activities Parties that we can use to do query.

just go contact entity >>  advanced find  :

1. select the Activities Parties and select participation type and set it to "To Recipient".

2. then select Activity entity(emails) and select status reason and set it to : "Pending" or "Failed"
as below:


after that you will have a list of all your contact with failed or pending emails sent to them.



The main difference between Business Units & Teams




Business Units:

 It's important for the security concept of Dynamics CRM. They define a kind of a boundary within you can define specific roles or permissions. They are also used to represent an organization structure.

Teams:

  Are used for ownership of a record, which is handy if you can't define a single owner. They are also used for easier sharing - you could share a record with a team, instead of sharing it with multiple persons. Another usage is to grant permissions to multiple users with grouping them into a team and assign a security role to the team.

CRM Email Router Manager Service is Stopped.

dears,

i was faced this problem a few months ago, the email router service is stoped and when i restart it never start and receive error "The Microsoft CRM Email Router service on Local Computer started and then stopped. Some services stop automatically if they have no work to do" 

So after research i recognize that the error related to email router state, it's stucked. after i see the event log i see this:

The E-mail router service cannot access system state file Microsoft.Crm.Tools.EmailAgent.SystemState.xml.

so after that i delete this file and restart the email router service and it's worked fine.

good luck.