Frederiek
2006-03-10 14:31:45 UTC
Hi,
I'm using Visual C++ 6.0 (VS6.0 SP6) on Windows XP Professional SP2.
I experience a problem with a custom build setting that executes my
executable after compilation and linkage, to perform some registration.
The problem is that apparently some DLLs fail to load, because my exe
didn't find them. Following is the message I get.
myprogram.exe - Unable To Locate Component
This application has failed to start because 3rdpartylib.dll was not
found. Re-installing the application may fix this problem.
I verified that the path for these DLLs is part of the PATH system
variable. So I don't understand why it can't find them. Furthermore
there is no problem with executing the release version of my exe. By
the way, the custom build setting is only needed for the debug version.
There is also not a problem with loading DLLs when I execute the debug
version. The problem only occurs through the custom build setting.
I found a solution, in that I need to explicitly set every directory
for DLLs being used by my executable, in the
Options->Directories->Executable files list. I cannot remember that I
ever needed to do this before. Doesn't VC use the PATH system variable
when performing custom build commands? I also restarted the system to
see if it was a temporary problem, but to no avail. The weird thing is,
it only happens with the custom build setting.
Does anybody know how I can avoid the need to indicate the location of
the used DLLs in this case?
Regards,
Frederiek
I'm using Visual C++ 6.0 (VS6.0 SP6) on Windows XP Professional SP2.
I experience a problem with a custom build setting that executes my
executable after compilation and linkage, to perform some registration.
The problem is that apparently some DLLs fail to load, because my exe
didn't find them. Following is the message I get.
myprogram.exe - Unable To Locate Component
This application has failed to start because 3rdpartylib.dll was not
found. Re-installing the application may fix this problem.
I verified that the path for these DLLs is part of the PATH system
variable. So I don't understand why it can't find them. Furthermore
there is no problem with executing the release version of my exe. By
the way, the custom build setting is only needed for the debug version.
There is also not a problem with loading DLLs when I execute the debug
version. The problem only occurs through the custom build setting.
I found a solution, in that I need to explicitly set every directory
for DLLs being used by my executable, in the
Options->Directories->Executable files list. I cannot remember that I
ever needed to do this before. Doesn't VC use the PATH system variable
when performing custom build commands? I also restarted the system to
see if it was a temporary problem, but to no avail. The weird thing is,
it only happens with the custom build setting.
Does anybody know how I can avoid the need to indicate the location of
the used DLLs in this case?
Regards,
Frederiek