Remove ScrollBars on GlideDialogForm

jeremyeperdue
Giga Expert

How can I remove the vertical scroll bars on a GlideDialogForm?

1 ACCEPTED SOLUTION

Venkat and others that helped,



I think we will live with the scroll bars. I was really hoping for something like .removeCloseDecoration()



ServiceNow advises against DOM Manipulation and after a few issues caused by the changes in Geneva (like labels going to legends), I am reluctant to pursue this. Also, this is for an integration. So when the integration upgrade happens we may see issues or they may have addressed this.


Thank you,


Jeremy


View solution in original post

11 REPLIES 11

Venkat and others that helped,



I think we will live with the scroll bars. I was really hoping for something like .removeCloseDecoration()



ServiceNow advises against DOM Manipulation and after a few issues caused by the changes in Geneva (like labels going to legends), I am reluctant to pursue this. Also, this is for an integration. So when the integration upgrade happens we may see issues or they may have addressed this.


Thank you,


Jeremy


I saw this thread while I was looking for an answer to something else, thought I'd paste in here what I did to accomplish the removal of the scrollbars. Still DOM manipulation though.



var modal = new GlideDialogForm('Known Issue', 'u_known_issues', testMethod());


modal.setPreference('sys_id',-1);


modal.setDialogHeightMax(400);


modal.setLoadCallback(function(iframeDoc){


  var dialogFrame = 'defaultView' in iframeDoc ? iframeDoc.defaultView : iframeDoc.parentWindow;


  var iframe = dialogFrame.frameElement;


  var dialog = $j(iframe).contents().find('.form_dialog')[0];


  dialogFrame = null;


});



modal.render();