<html>
<head>
<style>
P
{
margin:0px;
padding:0px
}
body
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body>After a lot of digging, I found the solution:<BR>
<BR>
<A href="http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=99693">http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=99693</A><BR><BR>Xiaofeng Zhao<BR>http://www.xzing.org<BR>errare humanum est<BR><BR><BR>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #008080 2px solid; MARGIN-RIGHT: 0px">
<HR id=EC_stopSpelling>
Date: Mon, 13 Nov 2006 17:16:44 -0500<BR>From: Xiaofeng_Zhao@virtualscopics.com<BR>To: vtkusers@vtk.org<BR>Subject: [vtkusers] Linking VTK library to Windows Forms Application directory<BR><BR>
<META content="Microsoft SafeHTML" name=Generator>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006>I'm trying to link the vtk library to a Windows Forms Application (with Common Language Runtime Support) directly (Visual Studio 2005 Professional Edition). I was able to build the application without error but was not able to start the application. It seems that the problem is due to the declaration of a static variable:</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT color=#0000ff size=2></FONT></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT color=#0000ff size=2>static</FONT><FONT size=2> vtkDebugLeaksManager vtkDebugLeaksManagerInstance;</FONT></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT size=2></FONT></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT size=2>in the header file "vtkDebugLeaksManager.h".</FONT></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT size=2></FONT></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT size=2>This is not a vtk specified problem since it can be reproduced in the simplest application, as long as a static library in which a static global variable is declared. </FONT></SPAN></FONT><FONT face=Arial size=2><SPAN class=EC_437380122-13112006><FONT size=2>I wonder if any one have seem the problem and know the cause of it and have a good solution.</DIV></FONT></SPAN></FONT>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV align=left><FONT face=Arial size=2>Xiaofeng Zhao</FONT></DIV>
<DIV align=left><FONT face=Arial size=2></FONT> </DIV>
<DIV align=left><FONT face=Arial size=2>VirtualScopics, LLC</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>350 Linden Oaks</FONT></DIV>
<DIV align=left><FONT face=Arial size=2>Rochester NY 14625</FONT></DIV>
<DIV> </DIV></BLOCKQUOTE><br /><hr />All-in-one security and maintenance for your PC. Get a free 90-day trial! <a href='http://www.windowsonecare.com/purchase/trial.aspx?sc_cid=wl_wlmail' target='_new'>Learn more!</a></body>
</html>