Folks, after a couple of years gap I've written another ComVisible library
which I'd like to test drive from a VBS script. The sanity check code below
compiles and registers okay, but the CreateObject call only spits out a
"can't create object" error. Is there some way I can just get more
information beyond this generic error? I had code like this working years
ago, but not now. Has anyone called ComVisible from VBS? -- Greg K
------------
set client = CreateObject("SBD.ComTest1")
ActiveX component can't create object: 'SBD.ComTest1'
------------
regasm /verbose /codebase ComTest1.dll
------------
[ComVisible(true)]
[Guid("3ce6db98-659d-4284-9334-bfeecc0ff059")]
public interface IFoobar
{
string GetVersion();
}
[ComVisible(true)]
[Guid("42d7c22a-2c4a-4f07-9a9c-094709f726ae")]
[ClassInterface(ClassInterfaceType.None)]
[ProgId("SBD.ComTest1")]
public class Foobar : IFoobar
{
[DispId(1)]
public string GetVersion()
{
return GetType().Assembly.GetName().Version.ToString();
}
}