Hide CRM form left hand side navigation item
===

I have my account entity linked to a custom entity called inspections, i only want these inspections to be created for accounts of a certain type. So when it isnt that type i want the left hand navigation to this entity to be hidden away. I've seen some code that says will hide it away, as long as you have the navID of the item. I've had a crack at hiding it using what i thought could be the ID but it hasnt worked, so i'm wondering if anyone knows how to get this ID, or if there is another way to do this?

The code i'm using to hide the navigation is below:

    var navitem = Xrm.Page.ui.navigation.items.get("nav_ts_inspection"); 

	    if (navitem != null)  
	    {           
	    	navitem.setVisible(false);
	    } 

Thanks