Re: Help with .NET DLL - Again...
BINGO! I think that was indeed the issue. I renamed the file variable and bam, no more error. Thanks very much. Man, I love this list. Stefan On 30 Jun 2011, at 21:41, Stefan Richter wrote: > > Good point, I'll try with a different naming convention. > > Regards > > Stefan > > > > On 30 Jun 2011, at 18:10, Leigh wrote: > >> >>> >>> >> >> Does #file# actually resolve to a string or a structure? Historically #file# >> was a reserved word like CFFILE. >> >> > > ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:346003 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Help with .NET DLL - Again...
Good point, I'll try with a different naming convention. Regards Stefan On 30 Jun 2011, at 18:10, Leigh wrote: > >> >> > > Does #file# actually resolve to a string or a structure? Historically #file# > was a reserved word like CFFILE. > > ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:346002 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Help with .NET DLL - Again...
Thanks, the server is 9.01 and I already have a very similar other DLL from the same company working on the same machine. I believe I updated the .NET connector previously after having some issues first time round. The OS is 64bit Win 2008. I'm not sure about the DLL itself, it was not marked as 32 or 64 bit. Any way to tell? Regards Stefan On 30 Jun 2011, at 18:09, Scott Stewart wrote: > > Just out of curiosity, > > 1) What version of CF and > 2) 32 bit or 64 bit OS > 3) 32 bit or 64 bit dll > > If it's CF 9.01 you need to update the .net connector as well, and > some manual configuration to get it to work.. > Secondly there are issues with 32 bit dll's running in a 64 bit environment. > > On Thu, Jun 30, 2011 at 12:59 PM, Stefan Richter > wrote: >> >> Hi guys, >> I could use some advice. I'm trying to use some methods from a .NET >> assembly. I'm instantiating it like this: >> >> >> > assembly="#DLL#"> >> >> If I dump the doc variable I see all the assembly methods. So far so good. >> >> I recall that I need to call init in CF to invoke the constructor, but when >> I do that (and pass a path to the document) I get the error: >> >> Unable to find a constructor for class Aspose.Words.Document that accepts >> parameters of type ( coldfusion.runtime.LocalScope ). >> >> >> According to the docs >> http://www.aspose.com/documentation/.net-components/aspose.words-for-.net/aspose.words.documentconstructor2.html >> I believe that I need to pass a string. >> >> In C# the example code looks like this: >> Document doc = new Document(MyDir + "Document.doc"); >> >> I was trying >> >> >> but receive the above error. >> >> I admit I am a bit out of my depth here, but previously I have used similar >> libraries successfully after some initial struggles and help from this list. >> >> Any tips appreciated. >> >> Regards, >> >> Stefan >> >> >> >> >> >> > > ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:346001 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Help with .NET DLL - Again...
> > Does #file# actually resolve to a string or a structure? Historically #file# was a reserved word like CFFILE. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345969 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Help with .NET DLL - Again...
Just out of curiosity, 1) What version of CF and 2) 32 bit or 64 bit OS 3) 32 bit or 64 bit dll If it's CF 9.01 you need to update the .net connector as well, and some manual configuration to get it to work.. Secondly there are issues with 32 bit dll's running in a 64 bit environment. On Thu, Jun 30, 2011 at 12:59 PM, Stefan Richter wrote: > > Hi guys, > I could use some advice. I'm trying to use some methods from a .NET assembly. > I'm instantiating it like this: > > > assembly="#DLL#"> > > If I dump the doc variable I see all the assembly methods. So far so good. > > I recall that I need to call init in CF to invoke the constructor, but when I > do that (and pass a path to the document) I get the error: > > Unable to find a constructor for class Aspose.Words.Document that accepts > parameters of type ( coldfusion.runtime.LocalScope ). > > > According to the docs > http://www.aspose.com/documentation/.net-components/aspose.words-for-.net/aspose.words.documentconstructor2.html > I believe that I need to pass a string. > > In C# the example code looks like this: > Document doc = new Document(MyDir + "Document.doc"); > > I was trying > > > but receive the above error. > > I admit I am a bit out of my depth here, but previously I have used similar > libraries successfully after some initial struggles and help from this list. > > Any tips appreciated. > > Regards, > > Stefan > > > > > > ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345968 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Help with .NET DLL - Again...
Hi guys, I could use some advice. I'm trying to use some methods from a .NET assembly. I'm instantiating it like this: If I dump the doc variable I see all the assembly methods. So far so good. I recall that I need to call init in CF to invoke the constructor, but when I do that (and pass a path to the document) I get the error: Unable to find a constructor for class Aspose.Words.Document that accepts parameters of type ( coldfusion.runtime.LocalScope ). According to the docs http://www.aspose.com/documentation/.net-components/aspose.words-for-.net/aspose.words.documentconstructor2.html I believe that I need to pass a string. In C# the example code looks like this: Document doc = new Document(MyDir + "Document.doc"); I was trying but receive the above error. I admit I am a bit out of my depth here, but previously I have used similar libraries successfully after some initial struggles and help from this list. Any tips appreciated. Regards, Stefan ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345966 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm