Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
85
creating word documents
posted

Hi,

I was having a look through the web forums etc as I was trying to get an answer to creating word documents with infragistics.  Is it possible to create word documents using net advatnage CLR 2.0 or do i need the latest version CLR3.0 to be able to create them?

Thanks for your help

Paul

Parents
No Data
Reply
  • 469350
    Offline posted

    Hi Paul,

    It is technically possible to create Word (or Excel) documents using the Infragistics assemblies.

    But CLR3 includes some packaging utilities that allow us to properly compress (package) the files. If you are using CLR2, those utilities do not exist, so you have to provide your own IPackageFactory. So when you create your WordDocumentWriter in CLR, you must pass in an IPackageFactory or you will get an exception.

    There is a sample of this installed with NetAdvantage (for Excel) which demonstrates the basics of how to implement the interface and use it. The sample is called "Excel 2007 Custom Packaging CS".

    But... the sample does not include actual packaging code or a third-party packaging utility. The sample (being just sample) actually uses the CLR3 packaging just to show you what you would do if you have another packaging utility.

    So, if you want to find, and buy, some other third-party packaging utility, or if you wanted to write your own packaging (compatible with Word/Excel, of course), then you could do it.

    But realistically, I know of no one who has ever done this. It's generally a lot easier just to use CLR3 and save yourself some headaches.

Children