protected override void Import() { ImportExport.Import(dgv, new List <string>() { "科目", "代碼" }); foreach (DataGridViewRow row in dgv.Rows) { if (row.IsNewRow) { continue; } DataGridViewCell cell = row.Cells[chCode.Index]; ValidateCodeFormat(cell, 5); } ValidateDuplication(dgv, chCode.Index, "代碼不能重覆"); ValidateDuplication(dgv, chSubject.Index, "科目不能重覆"); }
protected override void Export() { ImportExport.Export(dgv, "匯出科目代碼設定"); }