Click here to Skip to main content
15,949,686 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
i have a label say lblMsg, which receives text from database

Now asume text in this label as "

hello

how are you

"

i am setting this text to my RadioButton's text property,

When i view the page radio button and text appears in two different line due to


tag ,so i want to remove the first occurance of

tags how can i do this in C#?

Posted
Comments
Sandeep Mewara 29-Apr-12 13:10pm    
Not clear.
Sergey Alexandrovich Kryukov 29-Apr-12 17:03pm    
Not clear. How can a tag be in the text. Use "Improve question" above.
--SA
Dev-0001 30-Apr-12 1:10am    
share your code
Mohamed Mitwalli 30-Apr-12 1:16am    
Reason for my vote of 1
Not clear .

1 solution

Please check the page view source and first find out what tag is created, then you can use the different techniques to remove it, examples are REGEX, string.Replace() etc.

Hope this helps....
 
Share this answer
 
Comments
Kannannns 30-Apr-12 3:38am    
string.Replace() replaces all the <P> tag in text, i want to remove only the first occurrence of the tag.
AbdulMuheet 30-Apr-12 7:19am    
Hope this will help.
http://board.phpbuilder.com/board/showthread.php?t=10371272
Or search on google.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900