CRM 2011 Add a MsgBox to replace an Error Message

I have an error message that pops up when a user tries to add more characters to a description field than the limit allows.  The error is:

If I click Download Log File and read the error, it states:

Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Generic SQL error.Detail: 
<OrganizationServiceFault xmlns:i="" xmlns="">
  <ErrorDetails xmlns:d2p1="" />
  <Message>Generic SQL error.</Message>
  <InnerFault i:nil="true" />

[b] <TraceText>
[Nextgen.Crm.Plugin: Nextgen.Crm.Plugin.ProcessProjectionFromLineItem]
[4ecac274-ebad-e311-8c19-463500000031: Nextgen.Plugin.ProcessProjectionFromLineItem: Update of opportunityproduct]

Open in new window

How do I read the error specifically  [Nextgen.Plugin.ProcessProjectionFromLineItem: Update of opportunityproduct] and return a MsgBox that states: The description field is limited to 2000 characters

Also I would like to provide the user with an OK button on the MsgBox that puts them back in the Description field

Who is Participating?
Rikin ShahConnect With a Mentor Microsoft Dynamics CRM ConsultantCommented:

I would suggest you write a JS function which fires on OnChange event. Checks the length of the field and if the length is more than 2000 characters, trim it to 2000 characters.

References: (change the parameters to 0 and 1999)
apollo7Author Commented:
Thanks, I will give this a try.
apollo7Author Commented:
This works, thanks.
apollo7Author Commented:
This worked, thanks for the help.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.