[Insight-users] A runtime error : DLL directory must be in the PATH

Luis Ibanez luis.ibanez at kitware.com
Tue, 30 Dec 2003 12:59:48 -0500


Hi Peng,

Executables in Windows look for DLLs in their current
directory and in the PATH.

You simply need identify the directory where you have
ITKCommon.dll and add this directory to the PATH.
Note that you put only the directory, not the full
location of the .dll file.

Since you are using WindowsXP: Go to the icon "My Computer",
right click on it and select "Properties", then the "Advanced"
tab, and  click on the "Environment Variables" button.

A browser list of environment variable should appear,
select "path" and click on the "edit" button, then
add your directory where ITKCommon.dll is to the list
of  directories in the path.


Regards,


   Luis


----------------------
Peng Cheng wrote:

> 												peng-cheng at uiowa . edu
> 												2003-12-30
> Dear All,
> Thanks for answering my last question. here comes another problem again. :(
> When I run my .exe console application. it pop up a message box said:
> 
> "Unable To Locate Component
> This application has failed to start because ITKCommon.dll was not found. Re-installing the application may fix this problem."
> 
> I am using Windows XP + VC6.0 + ITK1.4.0 + CMake1.8
> I tried to rebuild the ITK,and add the path of the ITKCommon.dll to my program. still it does not work.
> 
> following is my CMakeList file: Anybody knows how to fix this problem? thanks a lot
> 
> PROJECT(Image)
> INCLUDE (${CMAKE_ROOT}/Modules/FindITK.cmake)
> 
> IF (USE_ITK_FILE)
>    INCLUDE (${USE_ITK_FILE})
> ENDIF (USE_ITK_FILE)
> 
> LINK_LIBRARIES( ITKAlgorithms ITKIO ITKBasicFilters ITKCommon itkvnl_algo itkvnl )
> LINK_LIBRARIES ( itkzlib itksys )
> 
> 
> SET( SRC_COMMON
>     ParameterMap.cxx
>    )
> 
> 
> ADD_EXECUTABLE( Image
>     MainFunction.cxx 
>     ${SRC_COMMON}
>     )
> 
> 
> Sincerely yours,
> Peng Cheng
> 
> Dept. of BME
> University of Iowa
> 
> 
> 
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk . org
> http://www . itk . org/mailman/listinfo/insight-users
>