diff --git a/unimarc/unimarc/UniMarc.csproj b/unimarc/unimarc/UniMarc.csproj index d592138..49409b9 100644 --- a/unimarc/unimarc/UniMarc.csproj +++ b/unimarc/unimarc/UniMarc.csproj @@ -378,6 +378,7 @@ Marc.cs + Form diff --git a/unimarc/unimarc/마크/MarcPlanItem.cs b/unimarc/unimarc/마크/MarcPlanItem.cs new file mode 100644 index 0000000..0ff3016 --- /dev/null +++ b/unimarc/unimarc/마크/MarcPlanItem.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace UniMarc.마크 +{ + public class MarcPlanItem + { + public string Idx { get; set; } + public string ListName { get; set; } + public string Date { get; set; } + public string User { get; set; } + public string ColCheck { get; set; } = "F"; + } +} diff --git a/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.Designer.cs b/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.Designer.cs index 0bb0eda..697a539 100644 --- a/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.Designer.cs +++ b/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.Designer.cs @@ -220,24 +220,28 @@ namespace UniMarc.마크 // idx // this.idx.HeaderText = "idx"; + this.idx.DataPropertyName = "Idx"; this.idx.Name = "idx"; this.idx.Visible = false; // // list_name // this.list_name.HeaderText = "목록명"; + this.list_name.DataPropertyName = "ListName"; this.list_name.Name = "list_name"; this.list_name.Width = 500; // // date // this.date.HeaderText = "등록일시"; + this.date.DataPropertyName = "Date"; this.date.Name = "date"; this.date.Width = 130; // // user // this.user.HeaderText = "등록자"; + this.user.DataPropertyName = "User"; this.user.Name = "user"; this.user.Width = 80; // @@ -245,6 +249,7 @@ namespace UniMarc.마크 // this.colCheck.FalseValue = "F"; this.colCheck.HeaderText = "V"; + this.colCheck.DataPropertyName = "ColCheck"; this.colCheck.IndeterminateValue = "F"; this.colCheck.Name = "colCheck"; this.colCheck.Resizable = System.Windows.Forms.DataGridViewTriState.True; diff --git a/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.cs b/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.cs index 7ffd4e3..22e12c6 100644 --- a/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.cs +++ b/unimarc/unimarc/마크/Marc_Plan_Sub_SelectList.cs @@ -57,7 +57,7 @@ namespace UniMarc.마크 public void btn_Search_Click(object sender, EventArgs e) { - dataGridView1.Rows.Clear(); + // dataGridView1.Rows.Clear(); string gu = cb_gu.Text; // 검색 필터 string text = tb_Search.Text; // 검색어 DB LIKE 검색 @@ -73,6 +73,7 @@ namespace UniMarc.마크 #region Search_Sub private void Input_Grid(string[] ary) { + List dataList = new List(); string[] grid = { "", "", "", "", "F" }; for(int a = 0; a < ary.Length; a++) { @@ -81,9 +82,22 @@ namespace UniMarc.마크 if (a % 4 == 2) grid[2] = ary[a]; if (a % 4 == 3) { grid[3] = ary[a]; - dataGridView1.Rows.Add(grid); + + MarcPlanItem item = new MarcPlanItem + { + Idx = grid[0], + ListName = grid[1], + Date = grid[2], + User = grid[3], + ColCheck = "F" + }; + dataList.Add(item); + //dataGridView1.Rows.Add(grid); } } + bs1.DataSource = dataList; + dataGridView1.AutoGenerateColumns = false; + dataGridView1.DataSource = bs1; } #endregion