<DIV>Thank you for your suggestion, Amy, </DIV>
<DIV>&nbsp; it is ok now, but I don't know why I should add this include path. because I have used vtkStdString successfully&nbsp;and I don't add this include path then. but now, when I&nbsp;recompile&nbsp;my codes, which had no error and used vtkStdString, &nbsp;I always get error. I don't know why. maybe,&nbsp;vtk build tree must be added in the include path?</DIV>
<DIV>&nbsp; thank you again!</DIV>
<DIV>&nbsp; Mark&nbsp;&nbsp;</DIV>
<DIV>&nbsp;</DIV>
<DIV style="PADDING-RIGHT: 0px; PADDING-LEFT: 0px; FONT-SIZE: 12px; PADDING-BOTTOM: 2px; PADDING-TOP: 2px; FONT-FAMILY: Arial Narrow">------------------------------------</DIV>
<DIV style="FONT-WEIGHT: normal">Hi Mark,<BR><BR>Make sure that your VTK *build* tree is in your include path; this is in <BR>order for your compiler to find vtkstd/string, which is configured in <BR>your VTK build tree. You will also need to have VTK/Common in your <BR>include path in order for the compiler to find vtkStdString.h.<BR><BR>- Amy<BR><BR>Mark Jefferson wrote:<BR>&gt; Hi, David,<BR>&gt; I have used vtkStdString just like you suggest. and I want to add some <BR>&gt; notation in the render window. I don't think the usage of vtkStdString <BR>&gt; is wrong. here is part of my codes :<BR>&gt; #include &lt;vtkStdString.h&gt;<BR>&gt; #include &lt;vtkScaledTextActor.h&gt;<BR>&gt; void main()<BR>&gt; {<BR>&gt; vtkStdString str("Images");<BR>&gt; vtkScaledTextActor * text = vtkScaledTextActor::New();<BR>&gt; text-&gt;SetInput(str);<BR>&gt; ... ...<BR>&gt; }<BR>&gt; but I always get a error when I compile my codes :<BR>&gt; *Cannot open include file: 'vtkstd/string': No such file or directory*<BR>&gt; but vtkstd/string doesn't exist in vtk, and I also could not find it.<BR>&gt; could you tell me how to modify it if I want to use class vtkStdString?<BR>&gt; thank you!<BR>&gt; MJ<BR>&gt; ------------------ Ô­Ê¼Óʼþ ------------------<BR>&gt; Are you using CMake to build your console application?<BR>&gt;<BR>&gt; See any of the projects in the VTK/Examples folder for example <BR>&gt; CMakeLists.txt files that show how to build a project that links to <BR>&gt; VTK using CMake. From such a project, using vtkStdString should simply <BR>&gt; be a matter of:<BR>&gt;<BR>&gt; #include "vtkStdString.h"<BR>&gt;<BR>&gt; void TestFunc()<BR>&gt; {<BR>&gt; vtkStdString s("hi there");<BR>&gt; // do something useful with s here...<BR>&gt; }<BR>&gt;<BR>&gt; What is the error you get if you try to use vtkStdString?<BR>&gt;<BR>&gt;<BR>&gt; On Sun, Apr 6, 2008 at 9:43 AM, Mark Jefferson &lt;mark.jefferson@qq.com <BR>&gt; &lt;mailto:mark.jefferson@qq.com&gt;&gt; wrote:<BR>&gt;<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Hi, David,<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; I have found vtkstd in CMakeLists.txt, but I don't know how to do<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; next? maybe, should I recompile VTK using CMake again? but I have<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; recompile vtk for many times, I still could not use class<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; vtkStdString.<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; MJ<BR>&gt;<BR>&gt; ------------------------------------------------------------------------<BR>&gt;<BR>&gt; _______________________________________________<BR>&gt; This is the private VTK discussion list.<BR>&gt; Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ<BR>&gt; Follow this link to subscribe/unsubscribe:<BR>&gt; http://www.vtk.org/mailman/listinfo/vtkusers<BR>&gt;&nbsp;&nbsp; <BR><BR>-- <BR>Amy Squillacote&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Phone: (256) 726-4839<BR>Computer Scientist&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Fax: (256) 726-4806<BR>CFD Research Corporation&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Web: http://www.cfdrc.com<BR>215 Wynn Drive, Suite 501<BR>Huntsville, AL&nbsp; 35805<BR><BR></DIV>