ASP > ASP.NET Migration (DISP_E_MEMBERNOTFOUND Error)

N

NvrBst

I'm having a problem with a "Member not found. (Exception from
HRESULT: 0x80020003 DISP_E_MEMBERNOTFOUND))" error. The origional ASP
is JScript, and the ASP.NET is JScript.NET.

I'm creating an object with the line 'var oMyO =
Server.CreateObject("Type.Class")'. I can successfuly call methods
from that object (AKA a "ResetAll(DWORD ID)" by doing "oMyO.ResetAll =
1;"). But I can't seem to call a "Reset(DWORD x, DWORD y, DWORD ID)"
method.

In ASP-JScript it works by doing "oMyO.Reset(1, 20) = 1;", but by
renaming the file to .aspx it give the above error. If I try
"oMyO.Reset = 1" I get a "Number of parameters specified does not
match the expected number." error so I assume it can see the method.
Am I just calling the method syntaxtically wrong in ASP.NET/
JScript.NET (compared to ASP/JScript)?

Eventhough the COM object works perfectly in ASP/JScript, could there
be a bug in the COM for ASP.NET thats throwing the exception? (The
ASP.NET page just says the error occured on the line I'm trying to
call the method from, so I'm not too sure if the actual code inside
the method that is throwing the exception or ASP.NET page just can't
find the method...). I don't have access to the COM object source but
I can send in a bug report if I need too.

I'm stuck :) If anyone has any suggestions I'd be very greatful. I'd
be happy to provide more info if needed.

NB
 
N

NvrBst

I'm having a problem with a "Member not found. (Exception from
HRESULT: 0x80020003 DISP_E_MEMBERNOTFOUND))" error. The origional ASP
is JScript, and the ASP.NET is JScript.NET.

I'm creating an object with the line 'var oMyO =
Server.CreateObject("Type.Class")'. I can successfuly call methods
from that object (AKA a "ResetAll(DWORD ID)" by doing "oMyO.ResetAll =
1;"). But I can't seem to call a "Reset(DWORD x, DWORD y, DWORD ID)"
method.

In ASP-JScript it works by doing "oMyO.Reset(1, 20) = 1;", but by
renaming the file to .aspx it give the above error. If I try
"oMyO.Reset = 1" I get a "Number of parameters specified does not
match the expected number." error so I assume it can see the method.
Am I just calling the method syntaxtically wrong in ASP.NET/
JScript.NET (compared to ASP/JScript)?

Eventhough the COM object works perfectly in ASP/JScript, could there
be a bug in the COM for ASP.NET thats throwing the exception? (The
ASP.NET page just says the error occured on the line I'm trying to
call the method from, so I'm not too sure if the actual code inside
the method that is throwing the exception or ASP.NET page just can't
find the method...). I don't have access to the COM object source but
I can send in a bug report if I need too.

I'm stuck :) If anyone has any suggestions I'd be very greatful. I'd
be happy to provide more info if needed.

NB

Was able to bypass the problem by overloading all the COM functions
with functions that only take a single string as input; had to marshal/
unmarshal the data inside the COM and JScript.NET.

Strange that calling the overloaded (Single Param set function) works
fine, but calling the origional three param set function doesn't work
in JScript.NET. All the Get functions worked fine no mater the number
of params as input. The COM object was made with VS6. All functions
worked in ASP, just not ASP.NET. Maybe a bug in RCW or something? I
a new to JScript.NET so maybe its something basic too.

Cheers
NB
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,709
Latest member
AustinMudi

Latest Threads

Top