I have two quick, easy questions on C# in Visual Studio. First, is there anything like the label, but for an area of text in the program? I would like to have multiple lines of text in my program, but can only seem to accomplish it with a DotNetBar label with wordwrap turned on.
Second, is there any way to have a hyperlink in the middle of the text without using a link label? If I wanted to generate text like “An update is available, please visit http://example.com to download it!”, is it possible to make the link clickable without having to position a link label in the middle of the text?
You can use a LinkLabel and set its LinkArea property:
The above will make the
http://example.coma link whilst the rest of the text in normal.Edit to answer comment:
There are various ways of handling the link. One way is to give the link a description (the URL) and then launch the URL using Process.Start.
And the event handler can read the description and launch the site: