hi..
im in need of a free word editor which can be used in my website..
if any1 knows where i can find it, please let me know.and also tell me how to use it too...
Thanks..
hi..
im in need of a free word editor which can be used in my website..
if any1 knows where i can find it, please let me know.and also tell me how to use it too...
Thanks..
As already suggested a browser editor (FreeTextBox) and wants to export the edited content to Word, the simplest, most reliable option is to treat the editor output as HTML and either stream that HTML to the browser as a .doc download or save the HTML to disk. Word will open HTML files saved with a .doc extension, so you avoid Office automation and can implement this quickly on an ASP.NET site. If you need a real .docx (no extension/format warning and better image handling), generate a .docx with the Open XML SDK or a third-party library instead.
Example (stream HTML to download; avoid Response.End()):
protected void btnSave_Click(object sender, EventArgs e)
{
// get the edited HTML from the editor control (control.Text or Request.Form["editorId"])
string editorHtml = myEditor.Text;
string html = "<html><head><meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\"/></head><body>"
+ editorHtml + "</body></html>";
byte[] bytes = System.Text.Encoding.UTF8.GetBytes(html);
Response.Clear();
Response.Buffer = true;
Response.ContentEncoding = System.Text.Encoding.UTF8;
Response.ContentType = "application/msword";
Response.AddHeader("Content-Disposition", "attachment; filename=Document.doc");
Response.BinaryWrite(bytes);
HttpContext.Current.ApplicationInstance.CompleteRequest();
} To save a .doc file server-side:
string path = Server.MapPath("~/App_Data/Document.doc");
System.IO.File.WriteAllText(path, html, System.Text.Encoding.UTF8); Key cautions and tips:
This approach matches what most sites use for quick exports while keeping server-side code simple and maintainable.
Jump to Post— Ramesh S 129FreeTextBox is a good one.
FreeTextBox is a good one.
hey thanks for the editor..but can u just suggest me that how can i save the data? im able to put it on my aspx page...but im not able to save the data.i want the data to be saved in .doc format.
please send me the process if u know..
thanks
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.