Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / XML / February 2008

Tip: Looking for answers? Try searching our database.

Import XHTML into Word 2003

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
leoman730 - 30 Jan 2008 15:11 GMT
Hi,
I hope someone can help out on this or sheering me to the right direction.
We are currently develop a c# application that will automatically generate
Word Doc.
The application will pull data from database and then through Tidy format
the data into VALID XHTML. And then, we take the XHTML, parse it, then using
Microsoft.Office.Interop.Word to generate the word doc on the fly.

So our problem is that, the algorithm we use the parse the data is not
correct, and the program may crashed if it parsing not correctly (it get into
an infinite loop).

We are trying to finding a better solution to manipulate this VALID XHTML
data, and import that into Word Document with CORRECT Word format.

If anyone can provide any solution to handle this, please drop me some
lines. I would really appreciated it you can give some suggestion. Thank you
very much.
Peter Flynn - 10 Feb 2008 23:57 GMT
> Hi,
> I hope someone can help out on this or sheering me to the right direction.
[quoted text clipped - 3 lines]
> the data into VALID XHTML. And then, we take the XHTML, parse it, then using
> Microsoft.Office.Interop.Word to generate the word doc on the fly.

Don't bother. Use XSLT to rewrite the XHTML very carefully with an
embedded CSS stylesheet, and rename the output file to end with .doc
Word will then blindly open it and it'll quack like a.doc file.

///Peter

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.