<div>Hi Pingkun,</div>
<div>Thanks for your reply. I found what's wrong.&nbsp;I still didn't include the *.dll files in the lib properly. After doing that, everything is just fine.&nbsp;<br>Cheers,</div>
<div>Ming<br>&nbsp;</div>
<div><span class="gmail_quote">On 2/2/06, <b class="gmail_sendername">Pingkun Yan</b> &lt;<a href="mailto:pingkun.yan@gmail.com">pingkun.yan@gmail.com</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Hi,<br><br>Have you tried to give your project and EXE file different names?<br><br>HTH,<br>Pingkun<br><br>
On 2/2/06, Ming Chao &lt;<a href="mailto:mingchao2005@gmail.com">mingchao2005@gmail.com</a>&gt; wrote:<br>&gt; Hi,<br>&gt;<br>&gt; I encountered a problem when running my program. The message says: &quot;This<br>&gt; application has failed to start because 
vtkCommon.dll was not found.<br>&gt; Re-installing the application may fix this problem.&quot; I checked this .dll<br>&gt; file does existed in the directory:<br>&gt; C:\ITK\InsightToolkit-Binary\bin\Debug. Also, from this
<br>&gt; mailing list I saw other ppl had a similar problem. The answer to this<br>&gt; question was to put the directory in the %PATH% and include it the libaries.<br>&gt; I did both and I checked with a HelloWorld test code and It ran fine. But
<br>&gt; when I tried to run a real program, this kept happening. My platform is:<br>&gt; WinXP + CMake2.2 + ITK2.2.0 + VC6.0. The following is my CMakeLists.txt:<br>&gt; ==================================================================
<br>&gt;<br>&gt;<br>&gt; # This project is designed to be built outside the Insight source tree.<br>&gt;<br>&gt; PROJECT(MyProject)<br>&gt;<br>&gt; # Find ITK.<br>&gt;<br>&gt; FIND_PACKAGE(ITK)<br>&gt;<br>&gt; IF(ITK_FOUND)
<br>&gt;<br>&gt; INCLUDE(${ITK_USE_FILE})<br>&gt;<br>&gt; ELSE(ITK_FOUND)<br>&gt;<br>&gt; MESSAGE(FATAL_ERROR<br>&gt;<br>&gt; &quot;Cannot build without ITK. Please set ITK_DIR.&quot;)<br>&gt;<br>&gt; ENDIF(ITK_FOUND)<br>
&gt;<br>&gt; LINK_LIBRARIES (<br>&gt;<br>&gt; ITKBasicFilters<br>&gt;<br>&gt; ITKCommon<br>&gt;<br>&gt; ITKIO<br>&gt;<br>&gt; ITKAlgorithms<br>&gt;<br>&gt; ITKFEM<br>&gt;<br>&gt; ITKStatistics<br>&gt;<br>&gt; )<br>&gt;<br>
&gt; ADD_EXECUTABLE(MyProject MyCode.cxx )<br>&gt;<br>&gt; TARGET_LINK_LIBRARIES(MyProject ITKCommon)<br>&gt;<br>&gt; ========================================================<br>&gt;<br>&gt; Does anybody have an idea what I am doing wrong?
<br>&gt;<br>&gt; Thanks,<br>&gt;<br>&gt; Ming<br>&gt; _______________________________________________<br>&gt; Insight-users mailing list<br>&gt; <a href="mailto:Insight-users@itk.org">Insight-users@itk.org</a><br>&gt; <a href="http://www.itk.org/mailman/listinfo/insight-users">
http://www.itk.org/mailman/listinfo/insight-users</a><br>&gt;<br>&gt;<br>&gt;<br></blockquote></div><br>