Hi Ignacio,
I've done the same thing in the past with various hardware references. I
think your problem lies with using local variables.
Local variables will not be transferable between DLLs and additionally they
will not hold there value between DLL calls (they get reinitialized on every
call). So, what you can do is pass the hardware reference back to
TestStand, so that it can pass it to the following DLL call, or you can
define a global variable the is used in both DLLs. Global variables will
maintain there values until the DLLs are unloaded, and are accessible to all
DLLs that have defined them. You will have to do some reading concerning
declaration modifiers (ex: static int VXIRef) but this should be reletively
easy to figure out.
Hope this helps
Denis
"
IgnacioFreijeiro" wrote in message
news:3a03eae2@newsgroups.ni.com...
>
> Hi,
>
> I'm having problems with dll flexible prototype adapter and vxi equipment.
> I inicialize a switch matrix (from Vxi-Technology) within a DLL and keep
> the handler it returns me in a local variable. Then I try to use this
handler
> in other step that call other DLL to manage the instrument but I receive
> a runtime error from the vi driver that says "invalid object or reference"
> with code -1073807346.
> Can anybody help me?
> Thanks.