« Back to blog

How to hide the "Close Opportunity" option in the Actions menu - Microsoft CRM 4.0

It's been a major peeve that there's no supported way to edit the "Close Opportunity" dialog box. In fact since I'm using Microsoft CRM Dynamics 4.0 Online there is no way period to edit any part of the Close Opportunity process. Well forget you, MS, I'll just build my own solution that actually better supports my company's business process!

And that's what I did. But I also wanted to take away the "Close Opportunity" link in the Actions menu. And since the ISV.CONFIG only lets you giveth, not taketh away it looked like I'd be needing a form load event. The bulk of the code came from this conversation, but for some reason they set the item to display inline instead of none. I fixed that and ended up with:

 

 

// Hide the Bid Close button
if (document.getElementById("_MIcomplete") != null)
{
var CLSBtn = document.getElementById("_MIcomplete");
CLSBtn.style.display = 'none';
}