public NpcDataView(NpcDataTable table, String rowFilter) { Columns = table.Columns; RowFilter = rowFilter; Rows = new NpcDataRows(); foreach (NpcDataRow oldRow in table.Rows) { if (((String)oldRow[1]).IndexOf(rowFilter) >= 0) { NpcDataRow newRow = new NpcDataRow(table); Rows.Add(newRow); for (int i = 0; i < Columns.Count; i++) { newRow[i] = oldRow[i]; } } } }
public NpcDataTable() { Columns = new NpcDataColumns(); Rows = new NpcDataRows(); }