Request a topic or
contact an Arke consultant
404-812-3123
All posts tagged 'crm'

Arke Systems Blog

Useful technical and business information straight from Arke.

About the author

Author Name is someone.
E-mail me Send mail

Recent comments

Archive

Authors

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2017

Parsing and Validating Phone Numbers in CRM 2011

First off, I would like to thank Joe Gill for getting me started down the right path.  In fact, I'm going to suggest that everyone click that link so you can use his helpful screenshots to navigate where to put the JS I'm about to post. 

In any case, I had not seen a full example of parsing a phone number in CRM 2011 as I had with CRM 4.0.  Since it is such a common need, I decided to make my own.  The following code will strip out all special characters, check and make sure it's a valid set of numbers, and then push it back to the field, parsed properly.  This is limited to 10-digit phone numbers at the moment, but the core structure should be easily expanded if you need different types of validation.

The nice thing is, this can point at any entity, and any attribute that holds a phone number.  I strongly recommend adding this to your standard JS library for all CRM 2011 projects.

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);
  }
}


Posted by Wayne Walton on Wednesday, June 22, 2011 4:34 PM
Permalink | Comments (0) | Post RSSRSS comment feed

CRM2011 CrmOnline CrmSvcUtil

This post is based off of the CRM2011 SDK. If you do not have a Windows Live DeviceID and Device Password, you will need to build and run CreateCRM2011Device. After running, it creates an XML file in  C:\Users\your_username\LiveDeviceID called LiveDevice.XML that contains your DeviceID and Device Password. You should first check to see if you have this file if you are unsure of whether or not you have a DeviceID and Password. Also, you will need to install WIF.

After you have created your DeviceID and Password, I recommend creating "CrmSvcUtil.exe.config" containing:

<configuration>
  <appSettings>
    <add key="deviceid" value="your_Device_ID" />
    <add key="devicepassword" value="your_Device_Password" />
  </appSettings>
<system.diagnostics>
  <trace autoflush="false" indentsize="4">
   <listeners>
    <add name="configConsoleListener"
     type="System.Diagnostics.ConsoleTraceListener">
       <filter type="System.Diagnostics.EventTypeFilter" initializeData="Error" />
    </add>
   </listeners>
  </trace>
 </system.diagnostics>
</configuration>

This config file will hold your DeviceID and Password and enable tracing for easier troubleshooting, should any errors occur.

If you try to run CrmSvcUtil the way the SDK shows, it will not work. There are switches that the SDK says to use that are not valid, they should be removed: /disco /partner /env /org.  The only switches that willbe needed to accomplish the task at hand are /url /out /username and /password.  With that in mind, your command should look like:

CrmSvcUtil.exe /out:Code.cs /url:https://Your_CRMOnline_URL/XRMServices/2011/Organization.svc "/username:Windows_Live_Username" "/password:Windows_Live_Password"

NOTE: The url MUST look exactly as above. It cannot end with "/" or "/$metadata" and should not be OrganizationData.svc


Posted by Michael Casciano on Thursday, January 6, 2011 11:33 AM
Permalink | Comments (0) | Post RSSRSS comment feed

Microsoft Dynamics CRM 4.0 Update Rollup 4 released

Why is seems like just yestarday we were posting about Update Rollup 3, and here comes Rollup 4!

 

You can find the KB article here: http://support.microsoft.com/kb/968176 

The actual files are here: http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=0ddf8e83-5d9c-4fe7-9ae6-f2713a024071#filelist  

Don't forget the updated help files!

One quick addendum, make sure you clear your Internet Explorer cache after installing on both the server and the client side.


Posted by Wayne Walton on Monday, May 11, 2009 2:16 PM
Permalink | Comments (0) | Post RSSRSS comment feed

Microsoft Dynamics CRM 4.0 Update Rollup 3 released

While at Convergence last week, Microsoft went ahead and released Update Rollup 3 for CRM 4.0.  You can get it here.

A few important notes:

  • Importing and exporting customizations is supported between servers with Update Rollup 2 and 3, but not supported between Release, Rollup 1 and Rollup 3. 
  • The CRM for Outlook Client has some memory usage issues resolved.
  • Performance issues with CRM related to the email router have been resolved.

Categories: CRM
Posted by Wayne Walton on Tuesday, March 17, 2009 10:26 AM
Permalink | Comments (0) | Post RSSRSS comment feed

Useful CRM links

For those of you who are looking for resources to help with CRM issues, or just to keep up on the news of CRM, I wanted to provide a few links.

So I hope that helps anyone looking for solutions and/or community for CRM.  If you are in LinkedIn, there are numerous CRM groups there as well.

Finally, Update Rollup 2 for CRM 4.0 has been released!  Get those patches up and running.


Categories: CRM
Posted by Wayne Walton on Thursday, January 22, 2009 11:30 AM
Permalink | Comments (0) | Post RSSRSS comment feed

Hiding and Changing Left Navigation Items in CRM 4.0 Entity Screens

First off, I want to give a big thank you to Jeremy Winchell for writing up the post that got me started in the right direction for this solution.

For those of you that customize Microsoft Dynamics CRM 4.0, like I do, then likely one of the things you repeatedly run into is clients and users that need to have better names for their actions.  Changing these names on the main navigation page relatively simple, but what about on all the other pages, like Contacts, Accounts, etc.?  These, for whatever reason Microsoft had, aren't removable or changeable.  It's a really painful oversight to have to tell a client that even though you have renamed "Products" to "Hardware", they're going to have to remember that it's still going to be "Products" in a few places.  Hopefully the next version of CRM will have the capability to alter and remove these natively, but until then, we'll have to roll our own.

 Warning, the following actions are not supported or even documented by Microsoft.  Use at your own risk.

Now that the disclaimer is out of the way, let's take a look at the meat of the solution.  First, go to the customization area of the Entity you want to change, and open its form view.  In there, click Form Properties and enable JavaScript for the OnLoad action.  The link above has pictures if you're not sure how to get there.

Now you will need the JavaScript:
document.getElementById("%variableName%").style.display = "none"

So in this line, %variableName% is the variable related to the button on the left-hand nav.  “none” will hide this element entirely.  (Also, make sure if you copy and paste that you don’t end up with retarded Word-style quotes.  That happened to me and I spent 10 minutes trying to find a typo in my code)

If you want to change the display name of a button, then you have a bit more work to do.

Again, the JavaScript:
document.getElementById("%variableName%").innerHTML= "<img src=\"%imageLocation%\" /> %displayName%";

Here, you will see that we’re using innerHTML to actually change the content of that button.  Now you don’t have to have the image code in here, but if you leave it out, then your link won’t have an image anymore, and will just be text.  If you want to keep the image, the best thing I have found is to use the IE Dev Toolbar and then look at that button’s properties (to get the IE Dev toolbar on a popup screen, hit Ctrl+N).  You will see the link to the default image there.  This is going to be different for every CRM install, so I have not included it on the table below. Then just change the Display Name with whatever you want the button to actually say, and you’re set!  Note that the quotes around the image location have to be escaped.

Below is a list of the links, their variable names, and their default Title.  From there, making changes to the left nav of any entity in CRM should be simple.   You will see repeats of some.  The reason for that is because MS was not 100% internally consistent in its naming scheme.  For example, Cases is IDed by both navService and navCases, depending on where you are.  For those, I would either try both, or check on the screen itself.

Link

Link ID Name

Default Title

Activities

navActivities

View Activities

Campaign Activities

navCampaignActivities

View Campaign Activities

Campaign Responses

navCampaignResponses

View Campaign Responses

Campaigns

navCampaignsInSFA

View Campaigns

Campaigns

navCampaignsInList

View Campaigns

Cases

navService

View Cases

Cases

navCases

View Cases

Competitors

navComp

View Competitors

Competitors

navComps

View Competitors

Contacts

navContacts

View Contacts

Contacts Excluded

navBulkOperationFailures

View Contacts Excluded

Contacts Selected

navTargetedMembers

View Contacts Selected

Contract Lines

navContractLines

View Contract Lines

Contracts

navContracts

View Contracts

Documents

navDoc

View Documents

E-mail Messages Created

navBulkOperationSuccesses

View E-mail Messages Created

Existing Products

navExistingProducts

View Existing Products

History

navActivityHistory

View History

Information

navInfo

View general information about this record

Invoices

navInvoices

View Invoices

Marketing List Members

navListMember

View Marketing List Members

Marketing Lists

navListsInSFA

View Marketing Lists

More Addresses

navAddresses

More Addresses

Opportunities

navOpps

View Opportunities

Orders

navOrders

View Orders

Other Contacts

navContacts

View Other Contacts

Planning Tasks

navTasks

View Planning Tasks

Price List Items

navPrices

View Price List Items

Products

navProducts

View Products

Quick Campaigns

navMiniCampaignsForList

View QuickCampaigns

Quotes

navQuotes

View Quotes

Related Campaigns

navCampaigns

View Related Campaigns

Relationships

navRelationships

View Relationships

Sales Literature

navCollaterals

View Sales Literature

Sales Literature

navSalesLit

View Sales Literature

Sub-Accounts

navSubAct

View Sub-Accounts

Sub-Contacts

navSubContacts

View Sub-Contacts

Substitutes

navSubs

View Substitutes

Target Marketing Lists

navTargetLists

View Target Marketing Lists

Target Products

navTargetProducts

View Target Products

Workflows

navAsyncOperations

View Workflows

Write-In Products

navWriteInProducts

View Write-In Products

 

So now you should have all the tools you need to customize the Entity Screens into something useful for your clients and users.  And don't forget, if you break something, you can always just delete the JavaScript and start over.


Posted by Wayne Walton on Tuesday, October 14, 2008 2:30 PM
Permalink | Comments (0) | Post RSSRSS comment feed

The Importance of Your Customer Data Lifecycle

This is a first of a series of articles I will be writing on customer data in business.  I'm starting off with a broad scope, but plan on breaking down into how CRM can help in these situations in future articles.

 

When you think of companies, what do you think of as their most important asset?  Is it what they produce?  If it the real estate they own?  Perhaps their employees, as so many are wont to claim.  While all of these might be important, none of it matters without customers.  A company’s information on their customers is their lifeline to continued success and profitability.  Without it, they have no reliable way to upsell their returning customers.  They have no way to follow up and make sure their customers’ needs are fulfilled.  Further, loss of customer information can lead to lawsuits and public embarrassment.  All told, the data you have on a customer has a lifecycle.

This lifecycle begins when you acquire a new customer.  Who is responsible for entering a customer’s data?  Does everyone follow established procedure when they enter new information? What is the initial follow-up procedure?  Consistency ensures that all future maintenance and manipulation can be done with a minimum of fuss. This is also a good time to ask questions of your new customers.  Most will appreciate the attention.  As a personal example, I enjoyed a particularly good beer recently, and wrote the maker, Anheuser-Busch asking them to produce more.  A couple weeks later, I got a call from them, wanting to know more.  They spent an hour on the phone with me, picking my brain about what I like.  In the end, they knew a lot about my beer habits, and I felt useful.

The main lifecycle of most customer data is while they are active customers.  This is the part that is most obviously critical to a business.  How are customers being upsold? What market trends can be gleaned from current sales? When they leave, why are customers leaving?  These three questions are closely tied together, and really lead to one determinant question.  Are you fulfilling your customers’ needs? Without the answer to this key problem, a company can never truly thrive.  As an example, Google’s whole business model is built around getting buyers and sellers together as effectively as possible.  Most people think of Google as a search company, but in reality their business is advertising.  Their AdWords (and its counterpart, AdSense) product is designed to create an efficient market where companies can bid on commonly used search terms.  Between this, and the ROI (return on investment) tools they offer to their customers, Google has built one of the most effective systems in the world of connecting company and customer.

Finally, in its end time, customer data must be secured and stored. Is there a data retention policy in place? What security measures are being taken to ensure that sensitive data is not inadvertently released? What is being done to mine this old customer information?  Old data is both a treasure trove and a security hazard. Properly analyzed, old data might reveal former customers that have a need of a new offering you have, or a fixable flaw in why you they are former customers.  Flipside, an embarrassing data leak can lead to a company being in the papers for all the wrong reasons.  Likely the most famous example is when CardSystems released 40 million credit card numbers accidentally.  Charges were even brought against them by the FTC.  This kind of loss could even sink a company.

The lifecycle of customer data is easily the most overlooked process in companies today.  As it is not a physical, tangible object, many tend to undervalue such information, even though it represents the core of what a company does. After all, without anyone to sell to, what would a business do?


Posted by Wayne Walton on Monday, March 17, 2008 2:16 PM
Permalink | Comments (0) | Post RSSRSS comment feed