I am .net coder and I am really really new to ColdFusion. I wrote a .dll library which automatically generates an invoice. I needed to use the library from a ColdFusion application. I have successfully loaded the classes in my library as coldfusion objects as I can call the methods. However, there is one method in my class which uses WordprocessingDocument which is a class of DocumentFormat.OpenXml.Packaging. I am actually getting this error :
System.IO.FileNotFoundException: Could not load file or assembly 'DocumentFormat.OpenXml, Version=2.5.5631.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. File name: 'DocumentFormat.OpenXml, Version=2.5.5631.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' at InvoiceLibrary.DocumentHandler.ConvertDocumentToDOCX(String file)
at InvoiceLibrary.DocumentHandler.ProcessDocument()
I have imported the DocumentFormat.OpenXml.dll so is the WindowsBase.dll files
<cfObject type=".NET" name="WordprocessingDocument"
class="DocumentFormat.OpenXml.Packaging.WordprocessingDocument"
assembly="C:\Users\mydocs\Documents\Visual Studio 2012\Projects\InvoiceGenerator\InvoiceLibrary\bin\Release\DocumentFormat.OpenXml.dll,C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\WindowsBase.dll">
I need your guidance to what am I doing wrong or what am I missing here?
{cf_install}/jnbridge/error.log
. Sometimes that log contain additional details about .net errors. – Leigh\jnbridge
directory. Also, in case it is relevant what is your full CF version? Check the CF Admin screen or use<cfdump var="#server.coldfusion#">
– Leigh