Hi,
I have a requirement like i want to upload and download user types content in a message box using ASP.net 4.0 like the one in c-sharpcorner. Can any one suggest a best way to do that? Can we stored the content in database or as an html file and retrive it which will be the best way to do that.
The content user will be entering can be a text, image, or any type of file. Please suggest some best approach or some links which has example of that.
Loading

Abhimanyu K VatsaRank #14 · 51.7K reputationPosted May 17, 2011, 5:09 AM EDT
karthik7 reputationPosted May 17, 2011, 5:15 AM EDT
Abhimanyu K VatsaRank #14 · 51.7K reputationPosted May 17, 2011, 6:23 AM EDT
think, how you insert record in db. just put some text in textbox and click on button...right?
this textbox will not let you edit your text like making bold, italic, formatting etc. so instead of using textbox use any html editor and a button. in the click event of that button you have to use file writing machenism and the file body data will be html editor data (formatted data)....
(i) html editor :
http://htmleditor.codeplex.com/
http://www.asp.net/ajax/ajaxcontroltoolkit/samples/htmleditor/htmleditor.aspx
(ii) file writing machenism:
http://www.dotnetspider.com/resources/26301-How-create-ASPX-Page-Dynamically-A-Step.aspx
Sam HobbsRank #107 · 20.5K reputationPosted May 17, 2011, 3:14 PM EDT