<div dir="ltr"><div>Hi all,</div><div>   I'm trying to run the Activiz PNG reader example:<br></div><div><a href="https://lorensen.github.io/VTKExamples/site/CSharp/IO/PNGReader/" target="_blank">https://lorensen.github.io/<wbr>VTKExamples/site/CSharp/IO/<wbr>PNGReader/</a><br></div><div><br></div><div>I changed filepath to be a png file on my machine:</div><div>string filePath = @"C:\Users\dgrop\Downloads\<wbr>cthead1.png";<br></div><div><br></div><div>And the file can be opened fine. However, the following line:</div><div>    imageViewer.SetRenderer(<wbr>renderer); <br></div><div><br></div><div>throws the following error:</div><div><br></div><div>System.<wbr>AccessViolationException</div>  HResult=0x80004003<br>  Message=Attempted to read or write protected memory. This is often an indication that other memory is corrupt.<br>  Source=<Cannot evaluate the exception source><br>  StackTrace:<br><Cannot evaluate the exception stack trace><br><div><br></div><div>I've tried moving the variable declarations to the Public Partial Class level as suggested here:<br></div><div><br></div><div><a href="http://vtk.1045678.n5.nabble.com/ActiViz-WindowColor-Memory-Corrupt-td5725980.html">http://vtk.1045678.n5.nabble.com/ActiViz-WindowColor-Memory-Corrupt-td5725980.html</a></div><div><br></div><div>but that did not change anything.</div><div><br></div><div>Any ideas on how to fix this?</div><div>    thanks in advance,</div><div>         -David<br></div></div>