Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.

Turn off/on expand to fit during initialize

Avatar

Level 1

Is there anyway to turn on/off expand to fit or Vertical Scroll during initialize.  Im workign on a Static Form and using javascript.  I was trying to use the

doNotScroll = true command when the user entered the field.  The issue is when that is used when expand to fit is enabled it limits a multiline field to a single line.

2 Replies

Avatar

Level 6

Try with this java script on docReady event.

var myDoc = event.target;
var f = myDoc.getField("rootlevelname[0].pagelevel[0].fieldname[0]");
f.doNotScroll = true;

Avatar

Level 1

Thank you for repling,  hate when post sit forever and no one respones.  I using basically the same command already but the issue is I need to have expand to fit on.  So when you using that code with expand to fit you only get a single line.   I modified the attachment below.  Maybe i will just make 2 fields a expandable and a none expandable and based of population hide one.  But I feel like that cheating.