Editing the Site Map – Dynamics CRM 4.0

Nathan Eccles, 23 April 2010

The Site Map is an xml file which controls the display of the main navigation in Dynamics CRM. By editing it we are able to change what the user sees in the navigation pane when they use CRM. Editing the Site Map can be a daunting task if you don’t know what you’re doing. However, it is also a useful file to edit to give your users a smoother experience and keep them out of areas they have no use for.

By default the Dynamics CRM navigation pane looks like the one on the left. By clicking the Personalize Workplace link you are able to add the sections: Sales, Marketing, Service, and Scheduling. After doing so your navigation will look like the one on the right.

However, using this method each user has to personalize their own workspace, and you’re still left with the un-needed tabs down the bottom. By editing the sitemap we are able to choose what is displayed in the Workplace tab for all users, and remove the tabs which are no longer needed.

To get started, let’s export the Site Map.

  1. Navigate to Settings, Customization, and then Export Customizations.
  2. Find and export the Site Map (SiteMap.xml) and save it somewhere easy to access.
  3. Extract the file from the zip folder and open it with whichever web editing program you prefer (notepad works fine).

 

 

 

 

 

 

The following shows a list of all the Elements you will see and use when editing the Site Map:

Element Name Description
Area Specifies the areas to show in the navigation pane.
Description Contains a description in one language.
Descriptions Contains a set of localized descriptions.
Group Specifies a group of subareas.
Privilege Controls whether a subarea is displayed for a given user.
SiteMap Specifies the root node for the site map.
SubArea Specifies the elements displayed in the left navigation pane for each area.
Title Contains a title in one language.
Titles Contains a set of localized titles for an area.

 

For more information on attributes I suggest looking at the Dynamics CRM SDK.

The first step I would advise taking when editing the Site Map is to permanently reveal any of the existing groups in the Workplace tab which you require.

  1. Find the Groups within the Workplace Area (right up the top).
  2. Find the particular group you would like to reveal..
  3. Remove the code: IsProfile=”true”

Below is a section of a sitemap which is set to reveal the Sales area in the Workplace, but not the Marketing area.

  • To remove any entities you do not wish to be displayed simply remove the SubArea (<SubArea... ...” />).
  • To move navigation links around, cut and paste the SubAreas into their appropriate positions.
  • To put navigation links into the Workplace tab (or anywhere else) that wouldn’t normally be there, copy and paste the appropriate SubArea into the correct position.

To hide these sub-areas you need to add a privilege tag (<Privilege... ...” />). This tag allows you to dictate who sees the navigation links based on what privileges their User Role allows. The following example shows that if the user’s role does not allow them to delete leads, then the SubArea is not displayed to them. (Multiple privileges may be required by separating the values with commas. Eg “Read,Create,Delete”)

Note also that the privilege tag must be placed between the <SubArea> and </SubArea> tags. This means that the ...” /> from the initial SubArea should be changed to ...”>

Here’s the list of the available Privilege values from the Dynamics CRM SDK:

  • All
  • AllowQuickCampaign
  • Append
  • AppendTo
  • Assign
  • Create
  • Delete
  • Read
  • Share

When all SubAreas in an Area are restricted due to privileges, the whole tab will be removed from that users display.

To apply the changes you have made to the site map:

  1. In CRM navigate to Settings, Customization, Import Customizations
  2. Browse for the site map file you have edited
  3. Click Open and then Upload (Note: If the site map is incorrectly formed you will receive the message “Either the file could not be uploaded, or this is not a valid Customization file.”)
  4. Click Import Selected Customizations

If you are looking to make changes to the sitemap layout you can also look into using the Microsoft Dynamics CRM Demonstration Tool which offers a graphical user interface to edit the sitemap.