Scroll bars in text box - how do you get them to work?

Ask your PowerShell-related questions, including questions on cmdlet development!
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
Locked
User avatar
daviesg6
Posts: 49
Joined: Thu Nov 21, 2013 12:36 pm

Scroll bars in text box - how do you get them to work?

Post by daviesg6 »

hi,

I have a need to add vertical scroll bars to a text box (read only box used to display search results). Because of the use of this box I cannot set it to a specific size and be sure it will display everything hence the scroll bars.
I have added this to the form, but it does nothing and I can't work out what is needed to get the scroll bar to make the data displayed actually scroll. Right now the indicator in the bar moves, but the data stays static.
I know it is going to be something obvious, but I think I've gone code blind.

Any suggestions?

jvierra
Posts: 14578
Joined: Tue May 22, 2007 9:57 am
Answers: 1
Been upvoted: 1 time
Contact:

Re: Scroll bars in text box - how do you get them to work?

Post by jvierra »

Scrollbars on text boxes are automatic. They display when needed.

jvierra
Posts: 14578
Joined: Tue May 22, 2007 9:57 am
Answers: 1
Been upvoted: 1 time
Contact:

Re: Scroll bars in text box - how do you get them to work?

Post by jvierra »

Here is a full demo of a textbox with full scrollbars:
Attachments
Demo-Text.pff
Download and run
(4.93 KiB) Downloaded 521 times

User avatar
daviesg6
Posts: 49
Joined: Thu Nov 21, 2013 12:36 pm

Re: Scroll bars in text box - how do you get them to work?

Post by daviesg6 »

I do not see the scroll bar, if I click the bottom right corner of the results window it moves down a line, but there is no bar.

I also cannot open the demo, it says it was created in a different version of primalforms

jvierra
Posts: 14578
Joined: Tue May 22, 2007 9:57 am
Answers: 1
Been upvoted: 1 time
Contact:

Re: Scroll bars in text box - how do you get them to work?

Post by jvierra »

Here it is as a PS1 file
Attachments
Demo-Text.Export.ps1
(7.18 KiB) Downloaded 939 times

User avatar
daviesg6
Posts: 49
Joined: Thu Nov 21, 2013 12:36 pm

Re: Scroll bars in text box - how do you get them to work?

Post by daviesg6 »

my apologies, I had not noticed the scroll bars option in the box config. Enabling this gave me the required option.

Locked