<div dir="ltr">I am using XP and vtk 5.10 RC2 and it works fine for me!<br><br>As someone mentioned you should check your dlls. Are you usng release DLLs and are you also building in release mode?<br><br>Jothy<br><br><div class="gmail_quote">
On Thu, Apr 26, 2012 at 3:23 PM, Wenlong <span dir="ltr"><<a href="mailto:scc.wwl@gmail.com" target="_blank">scc.wwl@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi, David & Jothy<br>
<div class="im"><br>
Thank you very much for your reply.<br>
<br>
</div><div class="im">Yes, I use x[2] = 3. That was a mistyping.<br>
<br>
</div><div class="im">I call vtkPoints->InsertPoint(1, x) without SetNumberOfComponents() in my<br>
previous application with Windows Vista & Visual Studio 2008 on another PC.<br>
It works. But as I call it in my current application with Windows 7 & Visual<br>
Studio 2008, the error pops up. I'm not sure if this is caused by different<br>
OS.<br>
<br>
A demo code #1 is like this<br>
<br>
{<br>
vtkPoints* points = vtkPoints::New();<br>
float x[3];<br>
x[0] = 0;<br>
x[1] = 1;<br>
x[2] = 2;<br>
points->InsertPoint(0, x); //where the access conflict happens<br>
}<br>
<br>
Another demo code #2 is<br>
<br>
{<br>
vtkGenericDataObjectReader* reader = vtkGenericDataObjectReader::New();<br>
reader->SetFileName("C:\\Users\\Wenlong\\Desktop\\surface.vtk");<br>
//where the access conflict happens<br>
reader->OpenVTKFile();<br>
reader->Update();<br>
}<br>
<br>
The same access conflict happens when the vtkGenericDataObjectReader<br>
instance try to get to the .vtk file. I check the file and it does exist and<br>
it is not occupied by any other program.<br>
<br>
I don't understand why this is happening cause I set the including<br>
directories and libraries as necessary.<br>
<br>
</div><div class="im">Thank you very much for your kindly help.<br>
<br>
Best regards<br>
Wenlong<br>
<br>
--<br>
</div>View this message in context: <a href="http://vtk.1045678.n5.nabble.com/About-vtkPoints-InsertPoint-tp5667490p5667760.html" target="_blank">http://vtk.1045678.n5.nabble.com/About-vtkPoints-InsertPoint-tp5667490p5667760.html</a><br>
<div class="im HOEnZb">Sent from the VTK - Users mailing list archive at Nabble.com.<br>
</div><div class="HOEnZb"><div class="h5">_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><div dir="ltr">Jothy<br></div><br>
</div>