Click here to Skip to main content
15,898,371 members

Comments by EaveTina (Top 2 by date)

EaveTina 24-Nov-15 2:06am View    
While searching for a solution to this I found a direct way of exporting a DataGridView control into an excel file.
All you need to do is use this method, it is provided with this C# library for excel files.
EaveTina 23-Nov-15 3:10am View    
Ira your problem occurs because you do not have MS Word installed on server, but note that Sergey gave some great points, especially the one regarding the usage of Word Interop in .NET on server side. This is really not recommended nor supported and the best is to avoid it and use some alternative instead.
But regarding the rest of his answer, I disagree and I presume that you also disagree as well.

First regarding the following statement: "...other Microsoft Office files. These files are best avoided". So let's say we avoid them, what would be an alternative? Use HTML to represent documents, spreadsheets and presentations, really? I feel that Sergey does not realize that it's not just about the formatting, office files provide quite a few additional features which have a large usage.

Nevertheless you did not mention that you need to view the document in the browser, so I'm not sure why he suggested the HTML in the first place.
Instead I would suggest you to take a look at some already available solution for converting Word files into PDF files with VB.NET. That solution uses a Word processing library for VB.NET, I hope this helps.