I have a legacy COM object that is written in C++. I register the COM library via an installer and in a C# wrapper application I instantiate the COM object like this
Type type = Type.GetTypeFromProgID("GrpSvr.GrpCall");
this.grouperServer = Activator.CreateInstance(type);
string strMsg = this.grouperServer.GroupInit(this.strCommandFilePath, true, true);
and I then use the COM object for various operations and these calls look like
int index = 2;
string strFieldName = "AXR";
this.grouperSever.MakeRec(strFieldName, index);
and these work fine (at first). Then, out-of-the-blue the calls just stop returning the correct result. I can confirm that I am passing in the correct values to a given method and at some point and at random, the grouperServer
object starts returning crap.
I cannot debug the library in the usual sense and have not used COM libraries before. The fact that I can pass one of the COM methods the same value in a loop and this method stops returning the correct result, suggest that this maybe an invocation problem with the Dynamic Language Runtime (DLR). My question then becomes
How can I find out what is wrong with/debug the COM object?
Thanks for your time.