Hmmm… Very odd indeed.  Does CFOBJECT style invocation work on the object which you are having problems with?

 

If both methods throw errors, I’m wagering something is incomplete in the COM object implementation.  If you don’t want to spend time mucking around in the original source, you could easily wrap that object in another object (VB, for example) and then call your new object from CF . . . that would be much less overhead than calling via HTTP proxies.

 

Also, if you don’t mind sharing the object, I can try it on our dev machines to see if it gives us problems.


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of David Mineer
Sent: Tuesday, March 02, 2004 8:55 AM
To: [EMAIL PROTECTED]
Subject: Re: [CFCDev] ASP Server.CreateObject vs CF cfobject

 

Accidentaly sent last email before I was done.

 

It is running under the system account.  Also,  This works:

 

<cfobject action="" type="com" class="scripting.FileSystemObject" name="Application.fso">

 

I can create com objects, just not that particular one.  Is there any way of using that asp code with cfhttp or anything like that.  maybe this would be a good workaround.  I do have the source code for the com object available, in delphi.  If I knew more maybe I could make some changes in there.  I have looked at livedocs and there is some info on this but the object I want to instantiate seems to meet all the requirements.

 

---------------------
David Mineer

 

---------------------
Don't wish it was easier; wish you were better.
Don't wish for less problems; wish for more skills.
Don't wish for less challenges; wish for more wisdom.

----- Original Message -----

Sent: Monday, March 01, 2004 10:14 PM

Subject: RE: [CFCDev] ASP Server.CreateObject vs CF cfobject

 

The service account under which CF runs has to have access rights to the COM objects.  Do you have CF running under the system account?  Or if it is under a user account, does that user account have access rights to the COM object?

 

Roland

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of David Mineer
Sent: Monday, March 01, 2004 9:59 PM
To: cfcdev
Subject: [CFCDev] ASP Server.CreateObject vs CF cfobject

 

I posted about this same issue a few days ago and got some responses.  Thank you.  I have made some progress but am still struggling to make this work.  I have an asp page that does exactly what I need, no problem, but the CF equivalent does not work.  See code below.  Can someone tell me what the difference is between the processes that asp and cold fusion run in?  Is there any way for me to troubleshoot this issue?  What does the fact that it runs in asp tell me?  Anything?  Can I assume that it should run in cf also?

 

I have an asp page with the following code on it.

Set ZP4 = Server.CreateObject("zp4ipcom.zp4com")

Works great.

On a cfm page I have:

<CFSET zp4 = CreateObject("com", "zp4ipcom.zp4com") />

This does not work and I get the following error.

Error Occurred While Processing Request
An exception occurred when instantiating a Com object.
The cause of this exception was that: java.lang.NullPointerException.

Why doesn't the cf code instantiate the com object correctly?

Would it have something to do with permissions. Do asp pages run different than .cfm pages in a security context or something like that? What exactly are the differences between the asp code and the cf code?

Any help is appreciated. TIA,

 

---------------------
David Mineer

 

---------------------
Don't wish it was easier; wish you were better.
Don't wish for less problems; wish for more skills.
Don't wish for less challenges; wish for more wisdom.

Reply via email to