6
Reply

Reverse string including multiline

jacobah

jacobah

Aug 31 2011 1:12 AM
1.7k
Hi
I try to take a string from multi line text box call "ReqText"
Reverse the string, then take him again to the text box
It is works, my problem is that: from multiline text it is became to single line
My code:
 char[] arr = ReqText.Text.ToCharArray(); // converting the textbox to char arrayArray.Reverse(arr); // reversing the text

ReqText.Text = strReversed;
string strReversed = new string(arr);

any help?
I try to repeat the reverse string as muliline again

 Thanks,



Answers (6)