Is there any way of building a composite control and overiding its databound
(I'm guessing the event name) so I can use the label without do the code all
the time? Bear in mind I am quite new the .net. Regards, Chris.
"Mark Rae" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> "Chris" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>>I am writing some text in a multiline text box to a database . When I
>>display this in a label all the breaks have disappeared. I will be using
>>formviews a lot so I need a solution that works with bound data. In ASP I
>>used to use the replace function to replace chr(13) with "<br>". I am not
>>sure the how to do this in .net. Is there some simple setting or do I have
>>create my own version of a label and overide an event. I am a little
>>unsure of how to do this. Regards, Chris.
>
>
> string strText = "This is a multiline label\\r\\nwith a line break";
> MyLabel.Text = strText.Replace(\\r\\n, "<br />");
>
>
> --
> http://www.markrae.net