Hi
I have created a component in C# that I am wanting to consume as a COM object in vbScript. I have gone through the process of giving it a GUID and strong name, registering it with the GAC, and registering it in the registry using regasm ... /tlb...
It has a very simple method called returnValue, which simply returns an integer:
public static int returnValue()
{
return 1;
}
In the vbScript, I have added a reference to the object and have tried to consume the object using:
Dim testObject As Object
Set testObject = Server.CreateObject("csCom.clsCom"
.
.
.
oneCell = testObject.returnValue()
However, this gives me an error message saying: "Object doesn't support this property or method" and occurs at the line:
oneCell = testObject.returnValue()
I'm sure there is a very obvious solution to this, but I've been looking at it for too long. Does anybody have any idea what could be causing this problem?
Thanks!
I have created a component in C# that I am wanting to consume as a COM object in vbScript. I have gone through the process of giving it a GUID and strong name, registering it with the GAC, and registering it in the registry using regasm ... /tlb...
It has a very simple method called returnValue, which simply returns an integer:
public static int returnValue()
{
return 1;
}
In the vbScript, I have added a reference to the object and have tried to consume the object using:
Dim testObject As Object
Set testObject = Server.CreateObject("csCom.clsCom"
.
.
.
oneCell = testObject.returnValue()
However, this gives me an error message saying: "Object doesn't support this property or method" and occurs at the line:
oneCell = testObject.returnValue()
I'm sure there is a very obvious solution to this, but I've been looking at it for too long. Does anybody have any idea what could be causing this problem?
Thanks!