ASP.NET C#
How to covert Web form to MSWord doc and print it
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Roei BarRank #1,271 · 1.4K reputationPosted Oct 2, 2009, 6:57 AM EDT
and for the print issue you can ues this code:
Object copies = "1"; Object pages = ""; Object range = Word.WdPrintOutRange.wdPrintAllDocument; Object items = Word.WdPrintOutItem.wdPrintDocumentContent; Object pageType = Word.WdPrintOutPages.wdPrintAllPages; Object oTrue = true; Object oFalse = false; Object oTemplatePath = templateFullPath; oWord.Visible = true;oWord.Selection.TypeText(letterData[fieldName].ToString()); } } oWord.ActiveDocument.PrintOut( ref oTrue, ref oFalse, ref range, ref oMissing, ref oMissing, ref oMissing, ref items, ref copies, ref pages, ref pageType, ref oFalse, ref oTrue, ref oMissing, ref oFalse, ref oMissing, ref oMissing, ref oMissing, ref oMissing);Master BillaRank #2,229 · 630 reputationPosted Oct 2, 2009, 11:23 PM EDT
See here is sample
http://asptutorials.net/C-SHARP/convert-ms-word-docs-to-html/
thank you