Hi @ZRZJOLIVEIRA
This is script to hide the Contact tab on a screen.
You can use this as basis to understand the logic and adjust it with your parameter.
var screenName=getCurrentScreenName();
var viewID='';
if(screenName=='OPPORTUNITY')
viewID='oppty_contact';
else if(screenName=='PLACE' || screenName=='REPAIRPORTALPLACE' || screenName=='TECHPORTALPLACE')
viewID='place_contact';
else if(screenName=='PRODUCT' || screenName=='DEALERPORTALPRODUCT' || screenName=='REPAIRPORTALPRODUCT' || screenName=='TECHPORTALPRODUCT')
viewID='product_contact';
else if(screenName=='QUOTE' ||
screenName=='WFDEMOPPTYQUOTE' ||
screenName=='WFDEMOQUOTECONTRACT' ||
screenName=='WFDEMOQUOTENONPART' ||
screenName=='WFDEMOQUOTEPART' ||
screenName=='WFQUOTE' ||
screenName=='WFQUOTECONTRACT' ||
screenName=='WFQUOTENONPART' ||
screenName=='WFQUOTENONPARTREQUEST' ||
screenName=='WFQUOTENONPARTRMA' ||
screenName=='WFQUOTEPART' ||
screenName=='WFQUOTEPARTREQUEST' ||
screenName=='WFQUOTEPARTRMA')
viewID='quote_contact';
else if(screenName=='REQUEST' || screenName=='TECHPORTALREQUEST' || screenName=='WARRANTYCLAIMS' || screenName=='DEALERPORTALWARRANTYCLAIMS')
viewID='request_contact';
setControlVisibility(viewID,'import_contact',false);
setControlVisibility(viewID,'export_contact',false);
Best regards,
Sven
@ZRZJOLIVEIRA
In the case the view ID is missing, you need to create a new one in the UI designer.
Please note, this is not related to the name to register.
Best regards,
Sven
Hi,
Thank you very much for your comments, but we are trying to hide one field on a specific tab (not the tab itself).
Best regards,
João Oliveira
a workaround suggestion…. copy the field into a user_def, then make the user_def visible or not instead?
Hi nickz,
Thank you for the suggestion...it’s not perfect (another field on the data model, new BR to copy the value from one field to another., etc) but it works.
Best regards,,