[vtkusers] vtkStringArray problem

mbcx9rb9 richard.j.brown at live.co.uk
Wed Dec 3 04:45:33 EST 2014


Hi all,

I'm trying to put all DICOM files within a directory into a vtkStringArray
so that I can check how many series there are. The problem, however, seems
to be that InsertNexValue() and SetNumberOfValues() followed by SetValue()
don't insert anything into the array. So, after a for loop of 160
vtkStdStrings, GetNumberOfValues() returns 160, but each value is empty.
Furthermore, GetValue() causes the program to crash. Any ideas?

I need to use vtkStringArray (as opposed to a vector of std::string etc.),
as this is the required argument for vtkDICOMSorter ( link
<http://www.cognitive-antics.net/vtk-dicom/classvtk_d_i_c_o_m_sorter.html#ab855980b32de52e0363b35a16bfdf153> 
). 

Any help greatly appreciated,
Rich



--
View this message in context: http://vtk.1045678.n5.nabble.com/vtkStringArray-problem-tp5729638.html
Sent from the VTK - Users mailing list archive at Nabble.com.


More information about the vtkusers mailing list