Microsoft Dynamics CRM 4.0 removing marketing and sales from account view

Posting a script that removes all sales and marketing entries from either
contact form left pane or account for left pane. Useful IDs in here. We
only use CRM for our Support Dept, so I have been removing all these entries
from the forms as well as from the sitemap.

// This code will remove the entries under Sales and Marketing tabs from the
nav
// bar on the Contact form.

// Sales area
var _NA_SFA;
//Quotes
var navQuotes;
//Orders
var navOrders;
//Invoices
var navInvoices;
//Opportunities
var navOpps;

//Marketing Area
var _NA_MA;
//Campaigns
var navCampaignsInSFA;
//Lists
var navListsInSFA;

_NA_SFA = document.all._NA_SFA;
navQuotes = document.all.navQuotes;
navOrders = document.all.navOrders;
navInvoices = document.all.navInvoices;
navOpps = document.all.navOpps;
_NA_MA = document.all. _NA_MA;
navCampaignsInSFA = document.all.navCampaignsInSFA;
navListsInSFA = document.all.navListsInSFA;
if (_NA_SFA != null) { _NA_SFA.style.display = “none”; }
if (navInvoices != null) { navInvoices.style.display = “none”; }
if (navOrders != null) { navOrders.style.display = “none”; }
if (navQuotes != null) { navQuotes.style.display = “none”;}
if (navOpps!= null) { navOpps.style.display = “none”;}

if (_NA_MA != null) { _NA_MA.style.display = “none”; }
if (navCampaignsInSFA != null) { navCampaignsInSFA.style.display = “none”; }
if (navListsInSFA != null) { navListsInSFA.style.display = “none”; }

else {
// error handling here
alert(“Error during OnLoad Script”);
}

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: