diff --git a/src/generic/grid.cpp b/src/generic/grid.cpp index 2d953a621e..c3752751b5 100644 --- a/src/generic/grid.cpp +++ b/src/generic/grid.cpp @@ -8213,7 +8213,7 @@ void wxGrid::StringToLines( const wxString& value, wxArrayString& lines ) startPos += pos + 1; } - if ( startPos < (int)value.length() ) + if ( startPos < (int)tVal.length() ) { lines.Add( tVal.Mid( startPos ) ); }