i have one textbox with property TextMode="MultiLine"on my aspx page(C#)
i entered data in that textbox & press enter to write next line
but while saving that multi line data in database it saves only single line data,
i want this data store in sql database in multi line format .
how it is possible ?plz
Iftikar HussainPosted Aug 24, 2013, 10:02 AM
While saving data from multiline textbox to database, it will save the next line data with \n or \r character (which will be not visible to us). So while display same data in same format you just need to replace these character with
SELECT REPLACE(yourcolumndata,'\r\n','
');
Regards,
Iftikar
Abhineet SrivastavaPosted Aug 24, 2013, 6:20 AM
Cheers!
Sanjeeb LenkaPosted Aug 24, 2013, 6:09 AM
ranjan sahooPosted Aug 24, 2013, 6:03 AM
Sanjeeb LenkaPosted Aug 24, 2013, 5:07 AM
In data base it will always show it in one line. you can't do it in database column. but you can do it in front end when retrieving the data and showing it in front end in the multiline textbox it will show it in multiline.