* unimarc
a. 팩스전송 완료. b. 마크목록 폼 작성중 1. 엑셀반출 기능 추가중 사용 작업중 2. 마크편집 폼 수정 중 (마크 반출 test프로젝트 진행완료, 본 프로젝트에 적용중. / 저장기능활성화 작업완료) 2-1. 기존의 칸채우기에서 예상되지 못한 버그가 발생하여 칸채우기 숨김. 2-2. 008태크 재배치 => TextBox에 적용완료. 변경사항 메모장으로 넘기는 작업 진행해야함. 2-3. 현재 TODO : 저장기능 TODOLIST 1. 팩스로 전송될 엑셀파일 밑작업마무리 (입력될 파라미터만 적용하면 실사용가능) 2. 알라딘API, 네이버 API연동중 자잘한 버그 수정작업 필요.
This commit is contained in:
		
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										166
									
								
								ISBN_Check_test/Form1.Designer.cs
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										166
									
								
								ISBN_Check_test/Form1.Designer.cs
									
									
									
										generated
									
									
									
								
							| @@ -29,18 +29,11 @@ namespace ISBN_Check_test | |||||||
|         /// </summary> |         /// </summary> | ||||||
|         private void InitializeComponent() |         private void InitializeComponent() | ||||||
|         { |         { | ||||||
|             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle(); |             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle(); | ||||||
|             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle(); |             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle(); | ||||||
|             this.cb_filter = new System.Windows.Forms.ComboBox(); |             this.cb_filter = new System.Windows.Forms.ComboBox(); | ||||||
|             this.button1 = new System.Windows.Forms.Button(); |             this.button1 = new System.Windows.Forms.Button(); | ||||||
|             this.dataGridView1 = new System.Windows.Forms.DataGridView(); |             this.dataGridView1 = new System.Windows.Forms.DataGridView(); | ||||||
|             this.label1 = new System.Windows.Forms.Label(); |  | ||||||
|             this.richTextBox1 = new System.Windows.Forms.RichTextBox(); |  | ||||||
|             this.start_idx = new System.Windows.Forms.TextBox(); |  | ||||||
|             this.end_idx = new System.Windows.Forms.TextBox(); |  | ||||||
|             this.label2 = new System.Windows.Forms.Label(); |  | ||||||
|             this.button2 = new System.Windows.Forms.Button(); |  | ||||||
|             this.cb_api = new System.Windows.Forms.ComboBox(); |  | ||||||
|             this.book_name = new System.Windows.Forms.DataGridViewTextBoxColumn(); |             this.book_name = new System.Windows.Forms.DataGridViewTextBoxColumn(); | ||||||
|             this.author = new System.Windows.Forms.DataGridViewTextBoxColumn(); |             this.author = new System.Windows.Forms.DataGridViewTextBoxColumn(); | ||||||
|             this.book_comp = new System.Windows.Forms.DataGridViewTextBoxColumn(); |             this.book_comp = new System.Windows.Forms.DataGridViewTextBoxColumn(); | ||||||
| @@ -51,6 +44,13 @@ namespace ISBN_Check_test | |||||||
|             this.category = new System.Windows.Forms.DataGridViewTextBoxColumn(); |             this.category = new System.Windows.Forms.DataGridViewTextBoxColumn(); | ||||||
|             this.sold_out = new System.Windows.Forms.DataGridViewTextBoxColumn(); |             this.sold_out = new System.Windows.Forms.DataGridViewTextBoxColumn(); | ||||||
|             this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn(); |             this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn(); | ||||||
|  |             this.label1 = new System.Windows.Forms.Label(); | ||||||
|  |             this.richTextBox1 = new System.Windows.Forms.RichTextBox(); | ||||||
|  |             this.start_idx = new System.Windows.Forms.TextBox(); | ||||||
|  |             this.end_idx = new System.Windows.Forms.TextBox(); | ||||||
|  |             this.label2 = new System.Windows.Forms.Label(); | ||||||
|  |             this.button2 = new System.Windows.Forms.Button(); | ||||||
|  |             this.cb_api = new System.Windows.Forms.ComboBox(); | ||||||
|             ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit(); |             ((System.ComponentModel.ISupportInitialize)(this.dataGridView1)).BeginInit(); | ||||||
|             this.SuspendLayout(); |             this.SuspendLayout(); | ||||||
|             //  |             //  | ||||||
| @@ -75,14 +75,14 @@ namespace ISBN_Check_test | |||||||
|             //  |             //  | ||||||
|             // dataGridView1 |             // dataGridView1 | ||||||
|             //  |             //  | ||||||
|             dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; |             dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; | ||||||
|             dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control; |             dataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Control; | ||||||
|             dataGridViewCellStyle1.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); |             dataGridViewCellStyle5.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); | ||||||
|             dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText; |             dataGridViewCellStyle5.ForeColor = System.Drawing.SystemColors.WindowText; | ||||||
|             dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight; |             dataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight; | ||||||
|             dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText; |             dataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText; | ||||||
|             dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True; |             dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.True; | ||||||
|             this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1; |             this.dataGridView1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle5; | ||||||
|             this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { |             this.dataGridView1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { | ||||||
|             this.book_name, |             this.book_name, | ||||||
|             this.author, |             this.author, | ||||||
| @@ -97,14 +97,14 @@ namespace ISBN_Check_test | |||||||
|             this.dataGridView1.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnF2; |             this.dataGridView1.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnF2; | ||||||
|             this.dataGridView1.Location = new System.Drawing.Point(12, 38); |             this.dataGridView1.Location = new System.Drawing.Point(12, 38); | ||||||
|             this.dataGridView1.Name = "dataGridView1"; |             this.dataGridView1.Name = "dataGridView1"; | ||||||
|             dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; |             dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter; | ||||||
|             dataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Control; |             dataGridViewCellStyle6.BackColor = System.Drawing.SystemColors.Control; | ||||||
|             dataGridViewCellStyle2.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); |             dataGridViewCellStyle6.Font = new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))); | ||||||
|             dataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.WindowText; |             dataGridViewCellStyle6.ForeColor = System.Drawing.SystemColors.WindowText; | ||||||
|             dataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight; |             dataGridViewCellStyle6.SelectionBackColor = System.Drawing.SystemColors.Highlight; | ||||||
|             dataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText; |             dataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText; | ||||||
|             dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.True; |             dataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.True; | ||||||
|             this.dataGridView1.RowHeadersDefaultCellStyle = dataGridViewCellStyle2; |             this.dataGridView1.RowHeadersDefaultCellStyle = dataGridViewCellStyle6; | ||||||
|             this.dataGridView1.RowTemplate.Height = 23; |             this.dataGridView1.RowTemplate.Height = 23; | ||||||
|             this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect; |             this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect; | ||||||
|             this.dataGridView1.Size = new System.Drawing.Size(892, 466); |             this.dataGridView1.Size = new System.Drawing.Size(892, 466); | ||||||
| @@ -114,6 +114,63 @@ namespace ISBN_Check_test | |||||||
|             this.dataGridView1.RowPostPaint += new System.Windows.Forms.DataGridViewRowPostPaintEventHandler(this.dataGridView1_RowPostPaint); |             this.dataGridView1.RowPostPaint += new System.Windows.Forms.DataGridViewRowPostPaintEventHandler(this.dataGridView1_RowPostPaint); | ||||||
|             this.dataGridView1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.dataGridView1_KeyDown); |             this.dataGridView1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.dataGridView1_KeyDown); | ||||||
|             //  |             //  | ||||||
|  |             // book_name | ||||||
|  |             //  | ||||||
|  |             this.book_name.HeaderText = "도서명"; | ||||||
|  |             this.book_name.Name = "book_name"; | ||||||
|  |             this.book_name.Width = 200; | ||||||
|  |             //  | ||||||
|  |             // author | ||||||
|  |             //  | ||||||
|  |             this.author.HeaderText = "저자"; | ||||||
|  |             this.author.Name = "author"; | ||||||
|  |             //  | ||||||
|  |             // book_comp | ||||||
|  |             //  | ||||||
|  |             this.book_comp.HeaderText = "출판사"; | ||||||
|  |             this.book_comp.Name = "book_comp"; | ||||||
|  |             //  | ||||||
|  |             // isbn | ||||||
|  |             //  | ||||||
|  |             this.isbn.HeaderText = "ISBN"; | ||||||
|  |             this.isbn.Name = "isbn"; | ||||||
|  |             this.isbn.Width = 70; | ||||||
|  |             //  | ||||||
|  |             // price | ||||||
|  |             //  | ||||||
|  |             this.price.HeaderText = "정가"; | ||||||
|  |             this.price.Name = "price"; | ||||||
|  |             this.price.Width = 60; | ||||||
|  |             //  | ||||||
|  |             // price2 | ||||||
|  |             //  | ||||||
|  |             this.price2.HeaderText = "판매가"; | ||||||
|  |             this.price2.Name = "price2"; | ||||||
|  |             this.price2.Width = 60; | ||||||
|  |             //  | ||||||
|  |             // pubDate | ||||||
|  |             //  | ||||||
|  |             this.pubDate.HeaderText = "출간일"; | ||||||
|  |             this.pubDate.Name = "pubDate"; | ||||||
|  |             this.pubDate.Width = 70; | ||||||
|  |             //  | ||||||
|  |             // category | ||||||
|  |             //  | ||||||
|  |             this.category.HeaderText = "카테고리"; | ||||||
|  |             this.category.Name = "category"; | ||||||
|  |             //  | ||||||
|  |             // sold_out | ||||||
|  |             //  | ||||||
|  |             this.sold_out.HeaderText = "품절/절판"; | ||||||
|  |             this.sold_out.Name = "sold_out"; | ||||||
|  |             this.sold_out.Width = 70; | ||||||
|  |             //  | ||||||
|  |             // Column1 | ||||||
|  |             //  | ||||||
|  |             this.Column1.HeaderText = "Column1"; | ||||||
|  |             this.Column1.Name = "Column1"; | ||||||
|  |             this.Column1.Visible = false; | ||||||
|  |             //  | ||||||
|             // label1 |             // label1 | ||||||
|             //  |             //  | ||||||
|             this.label1.AutoSize = true; |             this.label1.AutoSize = true; | ||||||
| @@ -177,68 +234,11 @@ namespace ISBN_Check_test | |||||||
|             this.cb_api.TabIndex = 0; |             this.cb_api.TabIndex = 0; | ||||||
|             this.cb_api.SelectedIndexChanged += new System.EventHandler(this.cb_api_SelectedIndexChanged); |             this.cb_api.SelectedIndexChanged += new System.EventHandler(this.cb_api_SelectedIndexChanged); | ||||||
|             //  |             //  | ||||||
|             // book_name |  | ||||||
|             //  |  | ||||||
|             this.book_name.HeaderText = "도서명"; |  | ||||||
|             this.book_name.Name = "book_name"; |  | ||||||
|             this.book_name.Width = 200; |  | ||||||
|             //  |  | ||||||
|             // author |  | ||||||
|             //  |  | ||||||
|             this.author.HeaderText = "저자"; |  | ||||||
|             this.author.Name = "author"; |  | ||||||
|             //  |  | ||||||
|             // book_comp |  | ||||||
|             //  |  | ||||||
|             this.book_comp.HeaderText = "출판사"; |  | ||||||
|             this.book_comp.Name = "book_comp"; |  | ||||||
|             //  |  | ||||||
|             // isbn |  | ||||||
|             //  |  | ||||||
|             this.isbn.HeaderText = "ISBN"; |  | ||||||
|             this.isbn.Name = "isbn"; |  | ||||||
|             this.isbn.Width = 70; |  | ||||||
|             //  |  | ||||||
|             // price |  | ||||||
|             //  |  | ||||||
|             this.price.HeaderText = "정가"; |  | ||||||
|             this.price.Name = "price"; |  | ||||||
|             this.price.Width = 60; |  | ||||||
|             //  |  | ||||||
|             // price2 |  | ||||||
|             //  |  | ||||||
|             this.price2.HeaderText = "판매가"; |  | ||||||
|             this.price2.Name = "price2"; |  | ||||||
|             this.price2.Width = 60; |  | ||||||
|             //  |  | ||||||
|             // pubDate |  | ||||||
|             //  |  | ||||||
|             this.pubDate.HeaderText = "출간일"; |  | ||||||
|             this.pubDate.Name = "pubDate"; |  | ||||||
|             this.pubDate.Width = 70; |  | ||||||
|             //  |  | ||||||
|             // category |  | ||||||
|             //  |  | ||||||
|             this.category.HeaderText = "카테고리"; |  | ||||||
|             this.category.Name = "category"; |  | ||||||
|             //  |  | ||||||
|             // sold_out |  | ||||||
|             //  |  | ||||||
|             this.sold_out.HeaderText = "품절/절판"; |  | ||||||
|             this.sold_out.Name = "sold_out"; |  | ||||||
|             this.sold_out.Width = 70; |  | ||||||
|             //  |  | ||||||
|             // Column1 |  | ||||||
|             //  |  | ||||||
|             this.Column1.HeaderText = "Column1"; |  | ||||||
|             this.Column1.Name = "Column1"; |  | ||||||
|             this.Column1.Visible = false; |  | ||||||
|             //  |  | ||||||
|             // Form1 |             // Form1 | ||||||
|             //  |             //  | ||||||
|             this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); |             this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F); | ||||||
|             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; |             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; | ||||||
|             this.ClientSize = new System.Drawing.Size(918, 618); |             this.ClientSize = new System.Drawing.Size(920, 618); | ||||||
|             this.Controls.Add(this.end_idx); |             this.Controls.Add(this.end_idx); | ||||||
|             this.Controls.Add(this.start_idx); |             this.Controls.Add(this.start_idx); | ||||||
|             this.Controls.Add(this.richTextBox1); |             this.Controls.Add(this.richTextBox1); | ||||||
|   | |||||||
| @@ -20,9 +20,7 @@ namespace ISBN_Check_test | |||||||
|         private void Form1_Load(object sender, EventArgs e) |         private void Form1_Load(object sender, EventArgs e) | ||||||
|         { |         { | ||||||
|             string[] api_list = { "알라딘", "네이버" }; |             string[] api_list = { "알라딘", "네이버" }; | ||||||
|             string[] filter_list = { "제목+저자", "제목", "저자", "출판사" }; |  | ||||||
|             cb_api.Items.AddRange(api_list); |             cb_api.Items.AddRange(api_list); | ||||||
|             cb_filter.Items.AddRange(filter_list); |  | ||||||
|         } |         } | ||||||
|         private void button2_Click(object sender, EventArgs e) |         private void button2_Click(object sender, EventArgs e) | ||||||
|         { |         { | ||||||
| @@ -37,6 +35,7 @@ namespace ISBN_Check_test | |||||||
|         private void button1_Click(object sender, EventArgs e) |         private void button1_Click(object sender, EventArgs e) | ||||||
|         { |         { | ||||||
|             if(cb_api.SelectedIndex == -1) { MessageBox.Show("조건이 선택되지 않았습니다."); return; } |             if(cb_api.SelectedIndex == -1) { MessageBox.Show("조건이 선택되지 않았습니다."); return; } | ||||||
|  |             if(cb_filter.SelectedIndex == -1) { MessageBox.Show("조건이 선택되지 않았습니다."); return; } | ||||||
|  |  | ||||||
|             Stopwatch stopwatch = new Stopwatch(); |             Stopwatch stopwatch = new Stopwatch(); | ||||||
|             stopwatch.Start(); |             stopwatch.Start(); | ||||||
| @@ -52,7 +51,6 @@ namespace ISBN_Check_test | |||||||
|             switch (cb_api.SelectedIndex) |             switch (cb_api.SelectedIndex) | ||||||
|             { |             { | ||||||
|                 case 0: |                 case 0: | ||||||
|                     if(cb_filter.SelectedIndex == -1) { MessageBox.Show("조건이 선택되지 않았습니다."); return; } |  | ||||||
|                     Aladin_API(dataGridView1, start, end); |                     Aladin_API(dataGridView1, start, end); | ||||||
|                     break; |                     break; | ||||||
|                 case 1: |                 case 1: | ||||||
| @@ -120,6 +118,11 @@ namespace ISBN_Check_test | |||||||
|  |  | ||||||
|             for(int a = start; a < end; a++) |             for(int a = start; a < end; a++) | ||||||
|             { |             { | ||||||
|  |                 if (gridview.Rows[a].DefaultCellStyle.BackColor == Color.Yellow) | ||||||
|  |                     continue; | ||||||
|  |                 else if (gridview.Rows[a].DefaultCellStyle.BackColor == Color.LightGray) | ||||||
|  |                     gridview.Rows[a].DefaultCellStyle.BackColor = Color.Empty; | ||||||
|  |  | ||||||
|                 string[] ArrayValue = { gridview.Rows[a].Cells["book_name"].Value.ToString(),  |                 string[] ArrayValue = { gridview.Rows[a].Cells["book_name"].Value.ToString(),  | ||||||
|                                         gridview.Rows[a].Cells["author"].Value.ToString(),  |                                         gridview.Rows[a].Cells["author"].Value.ToString(),  | ||||||
|                                         gridview.Rows[a].Cells["book_comp"].Value.ToString() }; |                                         gridview.Rows[a].Cells["book_comp"].Value.ToString() }; | ||||||
| @@ -167,7 +170,7 @@ namespace ISBN_Check_test | |||||||
|             if (data == "") {  return; } |             if (data == "") {  return; } | ||||||
|  |  | ||||||
|             // pubDate형 보기편하게 DateTime형으로 재정리 |             // pubDate형 보기편하게 DateTime형으로 재정리 | ||||||
|             newstring = String.Format("{0:yyyy/MM/dd HH:mm}", |             newstring = String.Format("{0:yyyy/MM/dd}", | ||||||
|                 DateTime.Parse(insert[5].Remove(insert[5].IndexOf(" G")))); |                 DateTime.Parse(insert[5].Remove(insert[5].IndexOf(" G")))); | ||||||
|  |  | ||||||
|             // 도서 분류 필요한 데이터로 재정리 |             // 도서 분류 필요한 데이터로 재정리 | ||||||
| @@ -196,36 +199,27 @@ namespace ISBN_Check_test | |||||||
|         } |         } | ||||||
|         void insert_By_Naver(string value, int row) |         void insert_By_Naver(string value, int row) | ||||||
|         { |         { | ||||||
|             value = value.Replace("<b>", ""); |  | ||||||
|             value = value.Replace("</b>", ""); |  | ||||||
|  |  | ||||||
|             if (row > 0) { dataGridView1.Rows[row - 1].Selected = false; } |             if (row > 0) { dataGridView1.Rows[row - 1].Selected = false; } | ||||||
|             dataGridView1.Rows[row].Selected = true; |             dataGridView1.Rows[row].Selected = true; | ||||||
|  |  | ||||||
|             if (value.Length > 0) { |  | ||||||
|                 dataGridView1.Rows[row].Cells["Column1"].Value = value; |  | ||||||
|                 dataGridView1.Rows[row].DefaultCellStyle.BackColor = Color.LightGray; |  | ||||||
|             } |  | ||||||
|  |  | ||||||
|             if (value == "") return; |             if (value == "") return; | ||||||
|  |  | ||||||
|             bool[] chk = { false, false, false }; |             value = value.Replace("<b>", ""); | ||||||
|             string book_name = dataGridView1.Rows[row].Cells["book_name"].Value.ToString(); |             value = value.Replace("</b>", ""); | ||||||
|             string author = dataGridView1.Rows[row].Cells["author"].Value.ToString(); |  | ||||||
|             string book_comp = dataGridView1.Rows[row].Cells["book_comp"].Value.ToString(); |  | ||||||
|             string[] sp_data = value.Split('\t'); |             string[] sp_data = value.Split('\t'); | ||||||
|  |  | ||||||
|             if (sp_data.Length > 1) return; |  | ||||||
|  |  | ||||||
|  |  | ||||||
|  |  | ||||||
|             /// TODO: 밑에 작업하세요 |  | ||||||
|             #region 이게 그 작업할 밑에임 |  | ||||||
|             // title author publisher isbn price pubdate / discount |  | ||||||
|             // title author publisher isbn price pubdate discount |  | ||||||
|             string[] grid = { "", "", "", "", "", "", "", "" }; |             string[] grid = { "", "", "", "", "", "", "", "" }; | ||||||
|  |  | ||||||
|             for (int a = 0; a < sp_data.Length; a++) |             #region 분류작업 | ||||||
|  |             /* 0 : 도서명 | ||||||
|  |              * 1 : 저자 | ||||||
|  |              * 2 : 출판사 | ||||||
|  |              * 3 : ISBN | ||||||
|  |              * 4 : 판매가 | ||||||
|  |              * 5 : 출간일 | ||||||
|  |              * 6 : 카테고리 | ||||||
|  |              * 7 : 품절/절판 */ | ||||||
|  |             for (int a = 0; a < sp_data.Length-1; a++) | ||||||
|             { |             { | ||||||
|                 string[] data = sp_data[a].Split('|'); |                 string[] data = sp_data[a].Split('|'); | ||||||
|                 int idx = data.Length - 2; |                 int idx = data.Length - 2; | ||||||
| @@ -244,19 +238,43 @@ namespace ISBN_Check_test | |||||||
|                 else |                 else | ||||||
|                     grid[3] = data[idx - 3]; |                     grid[3] = data[idx - 3]; | ||||||
|  |  | ||||||
|                 grid[5] = data[idx - 2]; |                 grid[4] = data[idx - 2]; | ||||||
|                 grid[6] = data[idx - 1]; |                 grid[5] = data[idx - 1]; | ||||||
|  |  | ||||||
|                 if (data[idx] == "") |                 if (data[idx] == "") | ||||||
|                     grid[8] = "절판"; |                     grid[7] = "절판"; | ||||||
|                 else |                 else | ||||||
|                     grid[8] = ""; |                     grid[7] = ""; | ||||||
|  |  | ||||||
|                 for(int b = 0; b < 9; b++) { |                 dataGridView1.Rows[row].Cells["Column1"].Value += string.Join("|", grid) + "|"; | ||||||
|                     grid[9] += grid[b]; |                 dataGridView1.Rows[row].DefaultCellStyle.BackColor = Color.LightGray; | ||||||
|                 } |  | ||||||
|             } |             } | ||||||
|  |             if (sp_data.Length > 1) return; | ||||||
|  |  | ||||||
|  |             if (row > 0) { dataGridView1.Rows[row - 1].Selected = false; } | ||||||
|  |             dataGridView1.Rows[row].Selected = true; | ||||||
|             #endregion |             #endregion | ||||||
|  |  | ||||||
|  |             bool[] chk = { false, false, false }; | ||||||
|  |             string book_name = dataGridView1.Rows[row].Cells["book_name"].Value.ToString(); | ||||||
|  |             string author = dataGridView1.Rows[row].Cells["author"].Value.ToString(); | ||||||
|  |             string book_comp = dataGridView1.Rows[row].Cells["book_comp"].Value.ToString(); | ||||||
|  |             string newstring = DateTime.ParseExact(grid[5], "yyyyMMdd", null).ToString("yyyy-MM-dd"); | ||||||
|  |  | ||||||
|  |             if (grid[0] == book_name) chk[0] = true; | ||||||
|  |             if (grid[1] == author) chk[1] = true; | ||||||
|  |             if (grid[2] == book_comp) chk[2] = true; | ||||||
|  |  | ||||||
|  |             if (chk[0] == true && chk[1] == true && chk[2] == true) | ||||||
|  |             { | ||||||
|  |                 dataGridView1.Rows[row].Cells["isbn"].Value = grid[3]; | ||||||
|  |                 dataGridView1.Rows[row].Cells["price2"].Value = grid[4]; | ||||||
|  |                 dataGridView1.Rows[row].Cells["pubDate"].Value = newstring; | ||||||
|  |                 dataGridView1.Rows[row].Cells["category"].Value = grid[6]; | ||||||
|  |                 dataGridView1.Rows[row].Cells["sold_out"].Value = grid[7]; | ||||||
|  |                 dataGridView1.Rows[row].DefaultCellStyle.BackColor = Color.Yellow; | ||||||
|  |             } | ||||||
|  |  | ||||||
|         } |         } | ||||||
|         private void dataGridView1_KeyDown(object sender, KeyEventArgs e) |         private void dataGridView1_KeyDown(object sender, KeyEventArgs e) | ||||||
|         { |         { | ||||||
| @@ -296,16 +314,19 @@ namespace ISBN_Check_test | |||||||
|         private void textBox1_KeyPress(object sender, KeyPressEventArgs e) |         private void textBox1_KeyPress(object sender, KeyPressEventArgs e) | ||||||
|         { |         { | ||||||
|             if (!(char.IsDigit(e.KeyChar) || e.KeyChar == Convert.ToChar(Keys.Back))) |             if (!(char.IsDigit(e.KeyChar) || e.KeyChar == Convert.ToChar(Keys.Back))) | ||||||
|             { |  | ||||||
|                 e.Handled = true; |                 e.Handled = true; | ||||||
|         } |         } | ||||||
|         } |  | ||||||
|         private void cb_api_SelectedIndexChanged(object sender, EventArgs e) |         private void cb_api_SelectedIndexChanged(object sender, EventArgs e) | ||||||
|         { |         { | ||||||
|             if(cb_api.SelectedIndex == 1) |             cb_filter.Items.Clear(); | ||||||
|                 cb_filter.Enabled = false; |             if (cb_api.SelectedIndex == 0) { | ||||||
|              |                 string[] aladin = { "도서명+저자", "도서명", "저자", "출판사" }; | ||||||
|             else cb_filter.Enabled = true;  |                 cb_filter.Items.AddRange(aladin); | ||||||
|  |             } | ||||||
|  |             else if (cb_api.SelectedIndex == 1) { | ||||||
|  |                 string[] naver = { "도서명+출판사" }; | ||||||
|  |                 cb_filter.Items.AddRange(naver); | ||||||
|  |             } | ||||||
|         } |         } | ||||||
|     } |     } | ||||||
| } | } | ||||||
|   | |||||||
							
								
								
									
										2
									
								
								ISBN_Check_test/Form2.Designer.cs
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										2
									
								
								ISBN_Check_test/Form2.Designer.cs
									
									
									
										generated
									
									
									
								
							| @@ -93,7 +93,9 @@ namespace ISBN_Check_test | |||||||
|             this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect; |             this.dataGridView1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect; | ||||||
|             this.dataGridView1.Size = new System.Drawing.Size(834, 589); |             this.dataGridView1.Size = new System.Drawing.Size(834, 589); | ||||||
|             this.dataGridView1.TabIndex = 4; |             this.dataGridView1.TabIndex = 4; | ||||||
|  |             this.dataGridView1.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellClick); | ||||||
|             this.dataGridView1.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellDoubleClick); |             this.dataGridView1.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView1_CellDoubleClick); | ||||||
|  |             this.dataGridView1.KeyDown += new System.Windows.Forms.KeyEventHandler(this.dataGridView1_KeyDown); | ||||||
|             //  |             //  | ||||||
|             // book_name |             // book_name | ||||||
|             //  |             //  | ||||||
|   | |||||||
| @@ -15,6 +15,7 @@ namespace ISBN_Check_test | |||||||
|         Form1 f1; |         Form1 f1; | ||||||
|         public int row; |         public int row; | ||||||
|         public string Call_API = string.Empty; |         public string Call_API = string.Empty; | ||||||
|  |         int rowidx; | ||||||
|         public Form2(Form1 _f1) |         public Form2(Form1 _f1) | ||||||
|         { |         { | ||||||
|             InitializeComponent(); |             InitializeComponent(); | ||||||
| @@ -22,15 +23,12 @@ namespace ISBN_Check_test | |||||||
|         } |         } | ||||||
|         private void Form2_Load(object sender, EventArgs e) |         private void Form2_Load(object sender, EventArgs e) | ||||||
|         { |         { | ||||||
|             // 호출 API에 따라 다르게 함수호출 |             Sort_data(); | ||||||
|             if (Call_API == "알라딘") |  | ||||||
|                 Aladin(); |  | ||||||
|             else if (Call_API == "네이버") |  | ||||||
|                 Naver(); |  | ||||||
|  |  | ||||||
|             // 비슷한거 색깔표시 |             // 비슷한거 색깔표시 | ||||||
|             same_chk(); |             same_chk(); | ||||||
|         } |         } | ||||||
|  |         #region KEEP | ||||||
|         private void Aladin() |         private void Aladin() | ||||||
|         { |         { | ||||||
|             tb_book_name.Text = f1.dataGridView1.Rows[row].Cells["book_name"].Value.ToString(); |             tb_book_name.Text = f1.dataGridView1.Rows[row].Cells["book_name"].Value.ToString(); | ||||||
| @@ -60,9 +58,46 @@ namespace ISBN_Check_test | |||||||
|                 if (a % 8 == 7) { grid[7] = tmp[a]; dataGridView1.Rows.Add(grid); } |                 if (a % 8 == 7) { grid[7] = tmp[a]; dataGridView1.Rows.Add(grid); } | ||||||
|             } |             } | ||||||
|         } |         } | ||||||
|         private void Naver() |         #endregion | ||||||
|  |         private void Sort_data() | ||||||
|         { |         { | ||||||
|             MessageBox.Show("네이버!"); |             tb_book_name.Text = f1.dataGridView1.Rows[row].Cells["book_name"].Value.ToString(); | ||||||
|  |             tb_author.Text = f1.dataGridView1.Rows[row].Cells["author"].Value.ToString(); | ||||||
|  |             tb_book_comp.Text = f1.dataGridView1.Rows[row].Cells["book_comp"].Value.ToString(); | ||||||
|  |  | ||||||
|  |             if (f1.dataGridView1.Rows[row].Cells["price"].Value != null) | ||||||
|  |             { | ||||||
|  |                 tb_price.Text = f1.dataGridView1.Rows[row].Cells["price"].Value.ToString(); | ||||||
|  |             } | ||||||
|  |             else { tb_price.Text = ""; } | ||||||
|  |  | ||||||
|  |             string data = f1.dataGridView1.Rows[row].Cells["Column1"].Value.ToString(); | ||||||
|  |  | ||||||
|  |             // 도서명 / 저자 / 출판사 / isbn / 출간일 / 카테고리 / 품절여부 | ||||||
|  |             string[] tmp = data.Split('|'); | ||||||
|  |             string[] grid = { "", "", "", "", "", "", "", "" }; | ||||||
|  |  | ||||||
|  |             for (int a = 0; a < tmp.Length; a++) | ||||||
|  |             { | ||||||
|  |                 if (a % 8 == 0) { grid[0] = tmp[a]; } | ||||||
|  |                 if (a % 8 == 1) { grid[1] = tmp[a]; } | ||||||
|  |                 if (a % 8 == 2) { grid[2] = tmp[a]; } | ||||||
|  |                 if (a % 8 == 3) { grid[3] = tmp[a]; } | ||||||
|  |                 if (a % 8 == 4) { grid[4] = tmp[a]; } | ||||||
|  |                 if (a % 8 == 5) { grid[5] = change_Date_type(tmp[a]); } | ||||||
|  |                 if (a % 8 == 6) { grid[6] = tmp[a]; } | ||||||
|  |                 if (a % 8 == 7) { grid[7] = tmp[a]; dataGridView1.Rows.Add(grid); } | ||||||
|  |             } | ||||||
|  |         } | ||||||
|  |         private string change_Date_type(string date)  | ||||||
|  |         { | ||||||
|  |             MessageBox.Show(date); | ||||||
|  |             if (Call_API == "알라딘") | ||||||
|  |                 return String.Format("{0:yyyy/MM/dd}", DateTime.Parse(date.Remove(date.IndexOf(" G")))); | ||||||
|  |             else if (Call_API == "네이버") | ||||||
|  |                 return DateTime.ParseExact(date, "yyyyMMdd", null).ToString("yyyy-MM-dd"); | ||||||
|  |             else | ||||||
|  |                 return "NULL"; | ||||||
|         } |         } | ||||||
|         private void same_chk() |         private void same_chk() | ||||||
|         { |         { | ||||||
| @@ -95,7 +130,8 @@ namespace ISBN_Check_test | |||||||
|         } |         } | ||||||
|         private void dataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e) |         private void dataGridView1_CellDoubleClick(object sender, DataGridViewCellEventArgs e) | ||||||
|         { |         { | ||||||
|             int rowidx = e.RowIndex; |              | ||||||
|  |             if(e != null) { rowidx = e.RowIndex;} | ||||||
|             string book_name = dataGridView1.Rows[rowidx].Cells["book_name"].Value.ToString(); |             string book_name = dataGridView1.Rows[rowidx].Cells["book_name"].Value.ToString(); | ||||||
|             string author = dataGridView1.Rows[rowidx].Cells["author"].Value.ToString(); |             string author = dataGridView1.Rows[rowidx].Cells["author"].Value.ToString(); | ||||||
|             string book_comp = dataGridView1.Rows[rowidx].Cells["book_comp"].Value.ToString(); |             string book_comp = dataGridView1.Rows[rowidx].Cells["book_comp"].Value.ToString(); | ||||||
| @@ -123,5 +159,15 @@ namespace ISBN_Check_test | |||||||
|         { |         { | ||||||
|             this.Close(); |             this.Close(); | ||||||
|         } |         } | ||||||
|  |         private void dataGridView1_KeyDown(object sender, KeyEventArgs e) | ||||||
|  |         { | ||||||
|  |             if(e.KeyCode == Keys.Enter) { dataGridView1_CellDoubleClick(null, null); } | ||||||
|  |             if (e.KeyCode == Keys.Up) { rowidx--; } | ||||||
|  |             if (e.KeyCode == Keys.Down) { rowidx++; } | ||||||
|  |         } | ||||||
|  |         private void dataGridView1_CellClick(object sender, DataGridViewCellEventArgs e) | ||||||
|  |         { | ||||||
|  |             rowidx = e.RowIndex; | ||||||
|  |         } | ||||||
|     } |     } | ||||||
| } | } | ||||||
|   | |||||||
| @@ -21,7 +21,7 @@ | |||||||
|           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> |           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> | ||||||
|         </dsig:Transforms> |         </dsig:Transforms> | ||||||
|         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> |         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> | ||||||
|         <dsig:DigestValue>efl4krx3CSCbKwwTCKRYgxkrRfUnUwa5WbV5js5WItI=</dsig:DigestValue> |         <dsig:DigestValue>+/QFnMzikEHHL4QMbvyi8MOGF+umK+kzVlyKoBJTe6s=</dsig:DigestValue> | ||||||
|       </hash> |       </hash> | ||||||
|     </dependentAssembly> |     </dependentAssembly> | ||||||
|   </dependency> |   </dependency> | ||||||
|   | |||||||
										
											Binary file not shown.
										
									
								
							| @@ -42,14 +42,14 @@ | |||||||
|     </dependentAssembly> |     </dependentAssembly> | ||||||
|   </dependency> |   </dependency> | ||||||
|   <dependency> |   <dependency> | ||||||
|     <dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="ISBN_Check_test.exe" size="34304"> |     <dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="ISBN_Check_test.exe" size="36864"> | ||||||
|       <assemblyIdentity name="ISBN_Check_test" version="1.0.0.0" language="neutral" processorArchitecture="msil" /> |       <assemblyIdentity name="ISBN_Check_test" version="1.0.0.0" language="neutral" processorArchitecture="msil" /> | ||||||
|       <hash> |       <hash> | ||||||
|         <dsig:Transforms> |         <dsig:Transforms> | ||||||
|           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> |           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> | ||||||
|         </dsig:Transforms> |         </dsig:Transforms> | ||||||
|         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> |         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> | ||||||
|         <dsig:DigestValue>FiFngrnlS6vXXZ/Znz0MXrYvz9z6tinSgMT0d0BUMF4=</dsig:DigestValue> |         <dsig:DigestValue>SOOnX22POSHiraDFCNYxppjMF3ygF/gf8T7aM7xUdtY=</dsig:DigestValue> | ||||||
|       </hash> |       </hash> | ||||||
|     </dependentAssembly> |     </dependentAssembly> | ||||||
|   </dependency> |   </dependency> | ||||||
| @@ -74,13 +74,13 @@ | |||||||
|       <dsig:DigestValue>R+Wg8QGvQVHX8T0ta/qbhH1bXkqY0fRnS3wBV3J0bN8=</dsig:DigestValue> |       <dsig:DigestValue>R+Wg8QGvQVHX8T0ta/qbhH1bXkqY0fRnS3wBV3J0bN8=</dsig:DigestValue> | ||||||
|     </hash> |     </hash> | ||||||
|   </file> |   </file> | ||||||
|   <file name="ISBN_Check_test.pdb" size="71168"> |   <file name="ISBN_Check_test.pdb" size="77312"> | ||||||
|     <hash> |     <hash> | ||||||
|       <dsig:Transforms> |       <dsig:Transforms> | ||||||
|         <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> |         <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> | ||||||
|       </dsig:Transforms> |       </dsig:Transforms> | ||||||
|       <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> |       <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> | ||||||
|       <dsig:DigestValue>KiY4qWIu6kYOuYKOOXOnTECz2v4N1Gk7Tb0K63FrE5U=</dsig:DigestValue> |       <dsig:DigestValue>8uDbux/zJosoV9pNNPCtMQxz9juWuhf/xOl2Kksa8aw=</dsig:DigestValue> | ||||||
|     </hash> |     </hash> | ||||||
|   </file> |   </file> | ||||||
| </asmv1:assembly> | </asmv1:assembly> | ||||||
										
											Binary file not shown.
										
									
								
							
										
											Binary file not shown.
										
									
								
							| @@ -21,7 +21,7 @@ | |||||||
|           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> |           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> | ||||||
|         </dsig:Transforms> |         </dsig:Transforms> | ||||||
|         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> |         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> | ||||||
|         <dsig:DigestValue>efl4krx3CSCbKwwTCKRYgxkrRfUnUwa5WbV5js5WItI=</dsig:DigestValue> |         <dsig:DigestValue>+/QFnMzikEHHL4QMbvyi8MOGF+umK+kzVlyKoBJTe6s=</dsig:DigestValue> | ||||||
|       </hash> |       </hash> | ||||||
|     </dependentAssembly> |     </dependentAssembly> | ||||||
|   </dependency> |   </dependency> | ||||||
|   | |||||||
										
											Binary file not shown.
										
									
								
							
										
											Binary file not shown.
										
									
								
							
										
											Binary file not shown.
										
									
								
							| @@ -42,14 +42,14 @@ | |||||||
|     </dependentAssembly> |     </dependentAssembly> | ||||||
|   </dependency> |   </dependency> | ||||||
|   <dependency> |   <dependency> | ||||||
|     <dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="ISBN_Check_test.exe" size="34304"> |     <dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="ISBN_Check_test.exe" size="36864"> | ||||||
|       <assemblyIdentity name="ISBN_Check_test" version="1.0.0.0" language="neutral" processorArchitecture="msil" /> |       <assemblyIdentity name="ISBN_Check_test" version="1.0.0.0" language="neutral" processorArchitecture="msil" /> | ||||||
|       <hash> |       <hash> | ||||||
|         <dsig:Transforms> |         <dsig:Transforms> | ||||||
|           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> |           <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> | ||||||
|         </dsig:Transforms> |         </dsig:Transforms> | ||||||
|         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> |         <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> | ||||||
|         <dsig:DigestValue>FiFngrnlS6vXXZ/Znz0MXrYvz9z6tinSgMT0d0BUMF4=</dsig:DigestValue> |         <dsig:DigestValue>SOOnX22POSHiraDFCNYxppjMF3ygF/gf8T7aM7xUdtY=</dsig:DigestValue> | ||||||
|       </hash> |       </hash> | ||||||
|     </dependentAssembly> |     </dependentAssembly> | ||||||
|   </dependency> |   </dependency> | ||||||
| @@ -74,13 +74,13 @@ | |||||||
|       <dsig:DigestValue>R+Wg8QGvQVHX8T0ta/qbhH1bXkqY0fRnS3wBV3J0bN8=</dsig:DigestValue> |       <dsig:DigestValue>R+Wg8QGvQVHX8T0ta/qbhH1bXkqY0fRnS3wBV3J0bN8=</dsig:DigestValue> | ||||||
|     </hash> |     </hash> | ||||||
|   </file> |   </file> | ||||||
|   <file name="ISBN_Check_test.pdb" size="71168"> |   <file name="ISBN_Check_test.pdb" size="77312"> | ||||||
|     <hash> |     <hash> | ||||||
|       <dsig:Transforms> |       <dsig:Transforms> | ||||||
|         <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> |         <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" /> | ||||||
|       </dsig:Transforms> |       </dsig:Transforms> | ||||||
|       <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> |       <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /> | ||||||
|       <dsig:DigestValue>KiY4qWIu6kYOuYKOOXOnTECz2v4N1Gk7Tb0K63FrE5U=</dsig:DigestValue> |       <dsig:DigestValue>8uDbux/zJosoV9pNNPCtMQxz9juWuhf/xOl2Kksa8aw=</dsig:DigestValue> | ||||||
|     </hash> |     </hash> | ||||||
|   </file> |   </file> | ||||||
| </asmv1:assembly> | </asmv1:assembly> | ||||||
										
											Binary file not shown.
										
									
								
							
										
											Binary file not shown.
										
									
								
							
										
											Binary file not shown.
										
									
								
							
		Reference in New Issue
	
	Block a user
	 SeungHo Yang
					SeungHo Yang