Skip to main content

Is it possible to remove the scroll bar of a Dialog System's MLE control?

  • February 15, 2013
  • 0 replies
  • 0 views

Problem:

Is it possible to remove the scroll bar of a Dialog System's MLE control?

Resolution:

It is not possible to remove the scrollbars from a standard Dialog System MLE control.

It is however possible to create a MLE (Multiple Line Entry field), by using the Programmed Controls Text Entry Field control.

Look at the sample under DialogSystem\\CommonControls\\TextEntry.

Open up the Screenset and modify the Window so that you can make the first Text Entry Control field larger by stretching it downwards, like an MLE.

Then save the screenset and regenerate the control program so that it uses the new coordinates.

Open up the control program EFDEMOTXTFLD.CBL and add the following two lines of code just prior to the last invoke in the Create-Entry-Field section.

          invoke aTextEntry "multiplelineentry"

          invoke aTextEntry "wordWrap"

          invoke aTextEntry "create"  *> This is the current last line of the section.

This will then turn the entry field into an MLE.

Any of the other methods for the EntryField class and Gadget class etc. can be used within the GUI class library in order to modify the behavior of the entry field.

There is probably also a method of removing the scrollbars directly from a DS MLE field by getting its object reference and then calling the noHorizontalScrollbar and noVerticalScrollbar methods but the method documented above is probably the easiest way to go.

Old KB# 5252

0 replies

Be the first to reply!