Swappy wrote:
hi,
Im running this code
No, you are not running that code. It won't even compile, as you don't
set any return value in the method.
It might not be possible to say what's wrong with the code that you are
running, as you are some other code that you are not running.
public Boolean IsLayoutOpen(String strLayoutName)
{
Layout Layout_Obj = null;
try
{
Layouts layouts = instrumentation.Layouts; //This call is
through COM object
Layout_Obj = layouts.Item(strLayoutName);
layouts = null;
}
}
This code i am running in a thread but while calling the
instrumnetation.Layouts (it is From COM object) it gives me exception "Object
does not match target type."
Can someone tell me why this error is coming & what is the solution to
resolve this problem.
What more information does the exception contain? For example, what is
the type of the exception? That would help to determine if the exception
occurs in the COM method or in the code that is calling the COM method.
How is the method declared in the COM code?
--
Göran Andersson
_____
http://www.guffa.com