newbie question about text boxes

  • Thread starter Thread starter Mark Reed
  • Start date Start date
M

Mark Reed

What is the proper way to set a text box where it would display a few
paragraphs of disclaimer? It would be textbox, with vertical scroll bar
to run through the text.

Is this done with a textbox and setting the text property...a label and
the text property..or another method?

It seems wrong to type so much text into a label object... and it seems
wrong to use a text box as well.... but I do not see any object for
creating a large block of text to display as I want.

Sorry for what is probabbly a seemingly clueless question...but in
reading my C# study book, I do not see this addressed.

I assume I could type it in as text assigned to a variable and make a
label equal that variable too...

just want to know the "right way".
 
Mark said:
What is the proper way to set a text box where it would display a few
paragraphs of disclaimer? It would be textbox, with vertical scroll bar
to run through the text.

Is this done with a textbox and setting the text property...a label and
the text property..or another method?

It seems wrong to type so much text into a label object... and it seems
wrong to use a text box as well.... but I do not see any object for
creating a large block of text to display as I want.

Sorry for what is probabbly a seemingly clueless question...but in
reading my C# study book, I do not see this addressed.

I assume I could type it in as text assigned to a variable and make a
label equal that variable too...

just want to know the "right way".

The right way is what you decide it to be in this case. You can use a
Label, TextBox, RichTextBox(if you want formatting control like bold).
Take a look at existing applications. If you look at installers they
often use a RichTextBox for the End User License Agreement.

As far as getting the text in there I would load the contents from a
file and assign that to the Text or RtfText property.
 
You can use the text box and change the properties on it to show a vertical
scroll bar and set it to be multiline which allows it to be sized to more
than a single line...

glenn
 
Mark,

I would use a textbox with

MultiLine = true
ReadOnly = true

I hope this helps

Cor
 
Back
Top