private void LineType_TableNewRow(object sender, System.Data.DataTableNewRowEventArgs e) { FFDataSet.LineTypeRow row = e.Row as FFDataSet.LineTypeRow; int max = (from LineType in this.LineType select LineType.id).Max(); row.id = max + 1; row.name = ""; }
/// <summary> /// Creates the object and keeps a reference to a new account type row. /// </summary> /// <param name="aRow"></param> public LineTypeModel() { this.lineTypeRow = MyData.getInstance().LineType.NewLineTypeRow(); MyData.getInstance().LineType.AddLineTypeRow(this.lineTypeRow); this.saveRow(); }
/// <summary> /// Creates the object and keeps a local referance to the given account type row. /// </summary> /// <param name="aRow"></param> public LineTypeModel(FFDataSet.LineTypeRow row) { this.lineTypeRow = row; }