NetSuite – Set Default Subtab

I had a request from a member of our logistics team to set the NetSuite Sales Order form to default to the logistics tracking tab when editing.
I did some research and found some tips on other sites which led me to this solution. I found how to add an event listener to the NetSuite forms from Marty Zigman’s blog.

First I needed to identify the tab, to do that I used the chrome developer tools. The code you are looking for will say ShowTab(‘tabname’,false). In this case my tab was ‘custom14’.

Once I had that tab name, I created the below script and deployed it on the sales order form edit as the before load event function. I have added a custom check for the NetSuite role (logistics role only) and calling ShowTab(“custom14”) to show the tab.

Leave a Reply

Your email address will not be published. Required fields are marked *