Having a lot of problems trying to get a .NET component running on an NT4 machine. Framework 1.1 is installed and the component is compiled under the same framework.
The component is a proxy for a web service which is called by a VB6 application. Unfortunately the VB6 application cannot create an instance of the component and reports the following error message 'ActiveX component can't create object'.
I wrote a simple .NET console test application which creates an instance of the proxy and calls GetStockQty. In this case everything works, the call is successful and the web service returns a valid quantity.
The signed proxy component has the following COM attributes:
[ComVisible(true)]
[Guid("D1576FA8-F3B1-4fa2-8018-677F6E483564")]
public interface IDataFeedProxy
{
[DispId(1)]
bool GetStockQty(string sku, out int quantity);
}
[ComVisible(true)]
[Guid("161A22E8-17C4-43f4-96A0-05FC439C7609"),
ClassInterface(ClassInterfaceType.None),
ComSourceInterfaces(typeof(IEvents))]
public class DataFeedProxy : IDataFeedProxy
It has been registered on the NT4 machine using the following:
regasm /codebase DataFeedWebService.dll /TLB
This works fine on an XP machine, Im only having these problems on the NT4 one. Its obviously COM related but Im at a loss as to what it could be.
Edit
This is how its done in the VB6 code:
Dim oProxy As DataFeedWebService.DataFeedProxy
Set oProxy = New DataFeedWebService.DataFeedProxy
bRet = oProxy.GetStockQty(sPluCode, lQuantity)
Set oProxy = Nothing
Ive also tried removing the reference from the VB6 project and creating it late bound with the same result.
Dim oProxy As Object
Set oProxy = CreateObject("DataFeedWebService.DataFeedProxy")