From Friday, January 17th 11 PM CDT (January 18th 5 AM UTC) through Saturday, January 18th 11:30 AM CDT (January 18th 5:30 PM UTC), ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Calling DLL2 from DLL1 from TestStand

Hi,

I have a TestStand sequence that calls function1 provided by DLL1.dll,
which in turn calls function2 in DLL2.dll.

If my test sequence consists of a single action, 'Call function1 from
DLL1.dll', the sequence fails with the error message 'Could not load
DLL or external library DLL1.dll'

If I insert a new action BEFORE this action, 'Call function2 from
DLL2.dll', both DLLs load with no problem, and the sequence operates as
expected, except that I have an additional unwanted call to function2.

(This extra call loads DLL2.dll, so it is already in memory when
DLL1.dll is loaded, so the second load is successful)

I have managed to reproduce this problem with the following
configurations:

1. DLL1.dll and DLL2.dll are regu
lar DLLs using MFC created with MSVC++
6.0.

2. DLL1.dll is a regular DLL using MFC created with MSVC++ 6.0, and
DLL2.dll is created with LabWindows/CVI 5.0.

Any ideas / suggestions as to how I can remove the initial call to
function2 are much appreciated.

Cheers,

Jerry


Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
0 Kudos
Message 1 of 3
(5,986 Views)
Jerry,

When DLL1 attempts to call DLL2, it can't find it in the DLL search
path. Either put DLL2 in the same directory as DLL1 or put DLL2 in the
Windows\System or Window\System32 (WinNT) directory. If DLL2 uses
a .UIR file, copy this also. If DLL2 calls other DLLs, they should be
in the DLL search path also.
TestStand loads DLL2 directly so it doesn't need to be in the search
path for TestStand to find it.

Let us know if this solves\doesn't solve the problem.
Paul Mueller
National Instruments


In article <7rnmlk$1lb$1@nnrp1.deja.com>,
jerry_gold@my-deja.com wrote:
> Hi,
>
> I have a TestStand sequence that calls function1 provided by DLL1.dll,
> which in turn calls function2 in DLL2.dll.
>
> If my test sequence consists of a single action, 'Call functio
n1 from
> DLL1.dll', the sequence fails with the error message 'Could not load
> DLL or external library DLL1.dll'
>
> If I insert a new action BEFORE this action, 'Call function2 from
> DLL2.dll', both DLLs load with no problem, and the sequence operates
as
> expected, except that I have an additional unwanted call to function2.
>
> (This extra call loads DLL2.dll, so it is already in memory when
> DLL1.dll is loaded, so the second load is successful)
>
> I have managed to reproduce this problem with the following
> configurations:
>
> 1. DLL1.dll and DLL2.dll are regular DLLs using MFC created with
MSVC++
> 6.0.
>
> 2. DLL1.dll is a regular DLL using MFC created with MSVC++ 6.0, and
> DLL2.dll is created with LabWindows/CVI 5.0.
>
> Any ideas / suggestions as to how I can remove the initial call to
> function2 are much appreciated.
>
> Cheers,
>
> Jerry
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.
>


Sent via Deja.com http://www.deja.com/
S
hare what you know. Learn what you don't.
0 Kudos
Message 2 of 3
(5,986 Views)
Thanks Paul, that's done the trick...

Cheers,

Jeremy

In article <7rqp5b$8ha$1@nnrp1.deja.com>,
paulmueller@my-deja.com wrote:
> Jerry,
>
> When DLL1 attempts to call DLL2, it can't find it in the DLL search
> path. Either put DLL2 in the same directory as DLL1 or put DLL2 in
the
> Windows\System or Window\System32 (WinNT) directory. If DLL2 uses
> a .UIR file, copy this also. If DLL2 calls other DLLs, they should be
> in the DLL search path also.
> TestStand loads DLL2 directly so it doesn't need to be in the search
> path for TestStand to find it.
>
> Let us know if this solves\doesn't solve the problem.
> Paul Mueller
> National Instruments
>
> In article <7rnmlk$1lb$1@nnrp1.deja.com>,
> jerry_gold@my-deja.com wrote:
> > Hi,
> >
> > I have a TestStand sequence that calls function1 provided by
DLL1.dll,
> > which in turn calls function2 in DLL2.dll.
> >
> > If my test sequence consists of a single action, 'Call function1
from
> > DLL1.dll', the sequence fails with the error message 'Could not load
> > DLL or external library DLL1.dll'
> >
> > If I insert a new action BEFORE this action, 'Call function2 from
> > DLL2.dll', both DLLs load with no problem, and the sequence operates
> as
> > expected, except that I have an additional unwanted call to
function2.
> >
> > (This extra call loads DLL2.dll, so it is already in memory when
> > DLL1.dll is loaded, so the second load is successful)
> >
> > I have managed to reproduce this problem with the following
> > configurations:
> >
> > 1. DLL1.dll and DLL2.dll are regular DLLs using MFC created with
> MSVC++
> > 6.0.
> >
> > 2. DLL1.dll is a regular DLL using MFC created with MSVC++ 6.0, and
> > DLL2.dll is created with LabWindows/CVI 5.0.
> >
> > Any ideas / suggestions as to how I can remove the initial call to
> > function2 are much appreciated.
> >
> > Cheers,
> >
> > Jerry
> >
> > Sent via Deja.com http://www.deja.com/
> > Share what you know. Learn what you don't.
> >
>
> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.
>


Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
0 Kudos
Message 3 of 3
(5,986 Views)