tags:

views:

57

answers:

3

I have a splash screen with multi-line text with minimal formatting (font size, font color, superscript, unerline).
How do I create a dialog with this multi-line text with formatting?

A: 

Create a Windows form that is and open it modally. If you need to know what the user clicked you can have it return a DialogResult value. You can display multiple line of text using either a Textbox and set the Readonly property to true or using a Label control. Both a Textbox and a Label have a Multiline property that you can set to true to allow multiple lines of text.

A: 

How is the text formatted? HTML? RTF? Or is that up to you?

Is the text static, or dynamic?

For no formatting, use a single label or multiple label controls. You can also use multiple label controls if you have completely separate labels that need different formatting.

For no formatting with a large amount of text that may wrap off the screen, use a read-only multi-line text box with a scrollbar.

For rich text, use a RichTextBox.

For HTML, drop in a WebBrowser control.

Paul Williams
Formatting is up to me. Text is static.
stan
Then I agree with Henk and R. Bemrose, use a `RichTextBox` and load it with some rich text. Make it read-only and multi-line.
Paul Williams
A: 

If you need formatted text, use a RichTextBox Control, with both ReadOnly = true; and Multiline = true;

Note that it's probably easier to make an RTF file that looks like you want it, then use RichTextBox's RichTextBbx1.LoadFile("path\to\file");

R. Bemrose