private void SetDataBind_CmbMenuTop() { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; M_WsMenuMainDB.DataMenuTop[] getData1 = null; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; reCode = wSvc.sMenuTopTreeView(out getData1, out reMsg); if (reCode == "Y") { if (getData1 != null && getData1.Length > 0) { Class.Common.ComboBoxItemSet setCmb = null; setCmb = new Class.Common.ComboBoxItemSet(); setCmb.AddColumn(); for (int i = 0; i < getData1.Length; i++) { string tmenuCd_val = getData1[i].TOP_MENU_CD.ToString(); string tmenuNm_val = getData1[i].TOP_MENU_NM.ToString(); setCmb.AddRow(getData1[i].TOP_MENU_NM.ToString(), getData1[i].TOP_MENU_CD.ToString()); } setCmb.Bind(cmbMenuTop); } } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuSetAuthSite.cs (Function)::SetDataBind_CmbMenuTop (Detail):: " + "\r\n" + ex.ToString()); } }
private void GetDbNm() { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; string reData = ""; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; reCode = wSvc.siteDbNm(AppInfo.SsSiteCd, out reData, out reMsg); if (reCode == "Y") { if (!string.IsNullOrEmpty(reData)) { _DBNM = reData; } //AppInfo.SsDbNm = reData; //AppInfo.SsSiteCd = cmbSite.SelectedValue.ToString(); // CMBBOX에서 선택된 SITE_CD 값을 APPINFO.SsSiteCD에 담는다 } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuSite.cs (Function)::GetDbNm (Detail)::reCode=[" + reCode + "], reMsg=[" + reMsg + "]", "Error"); logs.SaveLog("[error] (page)::FrmMenuSite.cs (Function)::GetDbNm (Detail)::" + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } }
private void SetDataBind_CmbSite() { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; M_WsMenuMainDB.DataSiteMainDB[] getData = null; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; reCode = wSvc.sSiteMainDB(AppInfo.SsMemcoCd, out getData, out reMsg); if (reCode == "Y") { if (getData != null && getData.Length > 0) { Class.Common.ComboBoxItemSet setCmb = null; setCmb = new Class.Common.ComboBoxItemSet(); setCmb.AddColumn(); for (int i = 0; i < getData.Length; i++) { setCmb.AddRow(getData[i].SITE_NM.ToString(), getData[i].SITE_CD.ToString()); } setCmb.Bind(cmbSite); } } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuSite.cs (Function)::SetDataBind_CmbSite (Detail):: " + "\r\n" + ex.ToString()); } }
private void SetDataBind_treeView1() { treeView1.Nodes.Clear(); M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; M_WsMenuMainDB.DataMenuTop[] getData1 = null; M_WsMenuMainDB.DataMenuSub[] getData2 = null; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; ImageList myimageList = new ImageList(); myimageList.Images.Add(Image.FromFile(@"Image\treeicon1.png")); treeView1.ImageList = myimageList; treeView1.ImageIndex = 0; reCode = wSvc.sMenuTopTreeView(out getData1, out reMsg); if (reCode == "Y") { if (getData1 != null && getData1.Length > 0) { for (int i = 0; i < getData1.Length; i++) { string tmenuCd_val = getData1[i].TOP_MENU_CD.ToString(); string tmenuNm_val = getData1[i].TOP_MENU_NM.ToString(); TreeNode root = new TreeNode(); root.Tag = "1-" + tmenuCd_val + "-0"; root.Text = tmenuNm_val; reCode = wSvc.sMenuSubTreeView(tmenuCd_val, out getData2, out reMsg); if (reCode == "Y") { if (getData2 != null && getData2.Length > 0) { for (int j = 0; j < getData2.Length; j++) { string smenuCd_val = getData2[j].SUB_MENU_CD.ToString(); string smenuNm_val = getData2[j].SUB_MENU_NM.ToString(); TreeNode node2 = new TreeNode(); node2.Tag = "2-" + tmenuCd_val + "-" + smenuCd_val; node2.Text = smenuNm_val; root.Nodes.Add(node2); } } } treeView1.Nodes.Add(root); if (treeView1.Nodes.Count > 0) { treeView1.SelectedNode = treeView1.GetNodeAt(0, 0); } } treeView1.ExpandAll(); } } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::SetDataBind_treeView1 (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } }
private void btnSave_Click(object sender, EventArgs e) { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; string reData = ""; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; int reCnt = 0; for (int i = 0; i < dataGridView1.Rows.Count; i++) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value != null) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value.ToString() == "1") { reCnt++; } } } if (reCnt < 1) { MessageBox.Show(msgRM.GetString("msgNotSelected")); return; } reCnt = 0; if (_codeGrp == "1") { for (int i = 0; i < dataGridView1.Rows.Count; i++) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value != null) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value.ToString() == "1") { string sMenuCd_val = dataGridView1.Rows[i].Cells["dgv1_SUB_MENU_CD"].Value.ToString(); string usingFlag_val = dataGridView1.Rows[i].Cells["dgv1_USING_FLAG"].Value.ToString(); string sortNo_val = "1"; if (dataGridView1.Rows[i].Cells["dgv1_SORT_NO"].Value != null) { sortNo_val = dataGridView1.Rows[i].Cells["dgv1_SORT_NO"].Value.ToString(); } reCode = wSvc.mMenuSub(_tMenuCd, sMenuCd_val, usingFlag_val, sortNo_val, out reMsg, out reData); if (reCode == "Y" && reData != "") { reCnt += Convert.ToInt16(reData); } } } } if (reCnt > 0) { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wSuccess") + " : " + reCnt.ToString()); } else { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wFail")); } SetDataBind_gridView1(_codeGrp, _tMenuCd, _sMenuCd); } if (_codeGrp == "2") { for (int i = 0; i < dataGridView1.Rows.Count; i++) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value != null) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value.ToString() == "1") { string menuCd_val = dataGridView1.Rows[i].Cells["dgv1_MENU_CD"].Value.ToString(); string usingFlag_val = dataGridView1.Rows[i].Cells["dgv1_USING_FLAG"].Value.ToString(); string sortNo_val = "1"; if (dataGridView1.Rows[i].Cells["dgv1_SORT_NO"].Value != null) { sortNo_val = dataGridView1.Rows[i].Cells["dgv1_SORT_NO"].Value.ToString(); } string menuPath_val = ""; if (dataGridView1.Rows[i].Cells["dgv1_MENU_PATH"].Value != null) { menuPath_val = dataGridView1.Rows[i].Cells["dgv1_MENU_PATH"].Value.ToString(); } string fileFolder_val = ""; if (dataGridView1.Rows[i].Cells["dgv1_FILE_FOLDER"].Value != null) { fileFolder_val = dataGridView1.Rows[i].Cells["dgv1_FILE_FOLDER"].Value.ToString(); } reCode = wSvc.mMenu(_tMenuCd, _sMenuCd, menuCd_val, usingFlag_val, sortNo_val, menuPath_val, fileFolder_val, out reMsg, out reData); if (reCode == "Y" && reData != "") { reCnt += Convert.ToInt16(reData); } } } } if (reCnt > 0) { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wSuccess") + " : " + reCnt.ToString()); } else { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wFail")); } SetDataBind_gridView1(_codeGrp, _tMenuCd, _sMenuCd); } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::btnSave_Click (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } }
private void dataGridView2_CellClick(object sender, DataGridViewCellEventArgs e) { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; string reData = ""; string colNm = dataGridView2.Columns[e.ColumnIndex].Name; if (colNm == "dgv2_BTNADD") { if (_codeGrp == "1") { string reVal = ChkDgv2ParamSubMenu(); if (reVal != "") { MessageBox.Show(wRM.GetString("wCheck") + " :: " + reVal); } else { string Nm_val = dataGridView2.Rows[0].Cells["dgv2_NM"].Value.ToString(); string sortNo_val = "1"; if (dataGridView2.Rows[0].Cells["dgv2_SORT_NO"].Value != null) { sortNo_val = dataGridView2.Rows[0].Cells["dgv2_SORT_NO"].Value.ToString(); } string pInputId = "1"; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; reCode = wSvc.exMenuSub(_sMenuCd, _tMenuCd, Nm_val, out reMsg, out reData); if (reCode == "Y" && reData != "0") { MessageBox.Show(msgRM.GetString("msgDuplicated")); } else { reCode = ""; reCode = wSvc.aMenuSub(_tMenuCd, Nm_val, "1", sortNo_val, pInputId, out reMsg, out reData); int reCnt = 0; if (reCode == "Y" && reData != "") { reCnt = Convert.ToInt16(reData); } if (reCnt > 0) { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wSuccess") + " : " + reCnt.ToString()); } else { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wFail")); } SetDataBind_gridView1(_codeGrp, _tMenuCd, _sMenuCd); } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::dataGridView2_CellClick (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } } } if (_codeGrp == "2") { string reVal = ChkDgv2ParamMenu(); if (reVal != "") { MessageBox.Show(wRM.GetString("wCheck") + " :: " + reVal); } else { string menuCd_val = dataGridView2.Rows[0].Cells["dgv2_MENU_CD"].Value.ToString(); string Nm_val = dataGridView2.Rows[0].Cells["dgv2_NM"].Value.ToString(); string sortNo_val = "1"; if (dataGridView2.Rows[0].Cells["dgv2_SORT_NO"].Value != null) { sortNo_val = dataGridView2.Rows[0].Cells["dgv2_SORT_NO"].Value.ToString(); } string menuPath_val = ""; if (dataGridView2.Rows[0].Cells["dgv2_MENU_PATH"].Value != null) { menuPath_val = dataGridView2.Rows[0].Cells["dgv2_MENU_PATH"].Value.ToString(); } string fileFolder_val = ""; if (dataGridView2.Rows[0].Cells["dgv2_FILE_FOLDER"].Value != null) { fileFolder_val = dataGridView2.Rows[0].Cells["dgv2_FILE_FOLDER"].Value.ToString(); } string pInputId = "1"; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; reCode = wSvc.exMenu(menuCd_val, _tMenuCd, _sMenuCd, out reMsg, out reData); if (reCode == "Y" && reData != "0") { MessageBox.Show(msgRM.GetString("msgDuplicated")); } else { reCode = ""; reCode = wSvc.aMenu(_tMenuCd, _sMenuCd, menuCd_val, Nm_val, "1", sortNo_val, menuPath_val, fileFolder_val, pInputId, out reMsg, out reData); int reCnt = 0; if (reCode == "Y" && reData != "") { reCnt = Convert.ToInt16(reData); } if (reCnt > 0) { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wSuccess") + " : " + reCnt.ToString()); } else { MessageBox.Show(wRM.GetString("wSave") + " " + wRM.GetString("wFail")); } SetDataBind_gridView1(_codeGrp, _tMenuCd, _sMenuCd); } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::dataGridView2_CellClick (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } } } } }
private void SetDataBind_gridView1(string code_grp, string tmenuCd, string smenuCd) { SetDataBind_grideView2(); M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; M_WsMenuMainDB.DataMenuSub[] getData2 = null; M_WsMenuMainDB.DataMenu[] getData3 = null; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; if (code_grp == "1") { dataGridView1.Columns["dgv1_APP_FLAG"].Visible = false; dataGridView1.Columns["dgv1_MENU_CD"].Visible = false; dataGridView2.Columns["dgv2_MENU_CD"].Visible = false; dataGridView1.Columns["dgv1_MENU_PATH"].Visible = false; dataGridView1.Columns["dgv1_FILE_FOLDER"].Visible = false; dataGridView2.Columns["dgv2_MENU_PATH"].Visible = false; dataGridView2.Columns["dgv2_FILE_FOLDER"].Visible = false; dataGridView1.Columns["dgv1_TOP_MENU_CD"].ReadOnly = true; dataGridView1.Columns["dgv1_SUB_MENU_CD"].ReadOnly = true; dataGridView1.Columns["dgv1_NM"].ReadOnly = true; reCode = wSvc.sMenuSubTreeView(tmenuCd, out getData2, out reMsg); if (reCode == "Y") { if (getData2 != null && getData2.Length > 0) { dataGridView1.Rows.Clear(); for (int i = 0; i < getData2.Length; i++) { dataGridView1.Rows.Add(); dataGridView1.Rows[i].Cells["dgv1_SUB_MENU_CD"].Value = getData2[i].SUB_MENU_CD.ToString(); dataGridView1.Rows[i].Cells["dgv1_TOP_MENU_CD"].Value = getData2[i].TOP_MENU_CD.ToString(); dataGridView1.Rows[i].Cells["dgv1_NM"].Value = getData2[i].SUB_MENU_NM.ToString(); dataGridView1.Rows[i].Cells["dgv1_USING_FLAG"].Value = getData2[i].USING_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_SORT_NO"].Value = getData2[i].SORT_NO.ToString(); } SetRowNumber(dataGridView1); } else { dataGridView1.Rows.Clear(); //MessageBox.Show("데이터가 없습니다"); } } } else if (code_grp == "2") { dataGridView1.Columns["dgv1_APP_FLAG"].Visible = false; dataGridView1.Columns["dgv1_MENU_CD"].Visible = true; dataGridView2.Columns["dgv2_MENU_CD"].Visible = true; dataGridView1.Columns["dgv1_MENU_PATH"].Visible = true; dataGridView1.Columns["dgv1_FILE_FOLDER"].Visible = true; dataGridView2.Columns["dgv2_MENU_PATH"].Visible = true; dataGridView2.Columns["dgv2_FILE_FOLDER"].Visible = true; dataGridView1.Columns["dgv1_TOP_MENU_CD"].ReadOnly = true; dataGridView1.Columns["dgv1_SUB_MENU_CD"].ReadOnly = true; dataGridView1.Columns["dgv1_MENU_CD"].ReadOnly = true; dataGridView2.Columns["dgv2_MENU_CD"].ReadOnly = false; dataGridView1.Columns["dgv1_NM"].ReadOnly = true; reCode = wSvc.sMenuTreeView(tmenuCd, smenuCd, out getData3, out reMsg); if (reCode == "Y") { if (getData3 != null && getData3.Length > 0) { dataGridView1.Rows.Clear(); for (int i = 0; i < getData3.Length; i++) { dataGridView1.Rows.Add(); dataGridView1.Rows[i].Cells["dgv1_MENU_CD"].Value = getData3[i].MENU_CD.ToString(); dataGridView1.Rows[i].Cells["dgv1_TOP_MENU_CD"].Value = getData3[i].TOP_MENU_CD.ToString(); dataGridView1.Rows[i].Cells["dgv1_SUB_MENU_CD"].Value = getData3[i].SUB_MENU_CD.ToString(); dataGridView1.Rows[i].Cells["dgv1_NM"].Value = getData3[i].MENU_NM.ToString(); dataGridView1.Rows[i].Cells["dgv1_USING_FLAG"].Value = getData3[i].USING_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_SORT_NO"].Value = getData3[i].SORT_NO.ToString(); dataGridView1.Rows[i].Cells["dgv1_MENU_PATH"].Value = getData3[i].MENU_PATH.ToString(); dataGridView1.Rows[i].Cells["dgv1_FILE_FOLDER"].Value = getData3[i].FILE_FOLDER.ToString(); } SetRowNumber(dataGridView1); } else { dataGridView1.Rows.Clear(); //MessageBox.Show("데이터가 없습니다"); } } } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::SetDataBind_gridView1 (Detail)::code_grp=[" + code_grp + "], tmenuCd=[" + tmenuCd + "], smenuCd=[" + smenuCd + "]", "Error"); logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::SetDataBind_gridView1 (Detail)::reMsg=[" + reMsg + "]", "Error"); logs.SaveLog("[error] (page)::FrmMenuMainDB.cs (Function)::SetDataBind_gridView1 (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } }
private void btnSave_Click(object sender, EventArgs e) { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; string reData = ""; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; int reCnt = 0; for (int i = 0; i < dataGridView1.Rows.Count; i++) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value != null) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value.ToString() == "1") { reCnt++; } } } if (reCnt < 1) { MessageBox.Show(msgRM.GetString("msgNotSelected")); return; } reCnt = 0; int reCnt2 = 0; if (_codeGrp == "1") { for (int i = 0; i < dataGridView1.Rows.Count; i++) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value != null) { if (dataGridView1.Rows[i].Cells["dgv1_CHK"].Value.ToString() == "1") { string menuCd_val = dataGridView1.Rows[i].Cells["dgv1_MENU_CD"].Value.ToString(); string viewFlag_val = dataGridView1.Rows[i].Cells["dgv1_VIEW_FLAG"].Value.ToString(); string newFlag_val = dataGridView1.Rows[i].Cells["dgv1_NEW_FLAG"].Value.ToString(); string modifyFlag_val = dataGridView1.Rows[i].Cells["dgv1_MODIFY_FLAG"].Value.ToString(); string delFlag_val = dataGridView1.Rows[i].Cells["dgv1_DEL_FLAG"].Value.ToString(); string reportFlag_val = dataGridView1.Rows[i].Cells["dgv1_REPORT_FLAG"].Value.ToString(); string printFlag_val = dataGridView1.Rows[i].Cells["dgv1_PRINT_FLAG"].Value.ToString(); string downloadFlag_val = dataGridView1.Rows[i].Cells["dgv1_DOWNLOAD_FLAG"].Value.ToString(); string pInputId = "1"; reCode = wSvc.mSetAuthSiteMemberDB(_dbNm, AppInfo.SsSiteCd, menuCd_val, cmbSite.SelectedValue.ToString(), viewFlag_val, newFlag_val, modifyFlag_val, delFlag_val, reportFlag_val, printFlag_val, downloadFlag_val, pInputId, out reMsg, out reData); if (reCode == "Y") { if (Convert.ToInt16(reData) < 1) { reCode = wSvc.aSetAuthSiteMemberDB(_dbNm, AppInfo.SsSiteCd, menuCd_val, cmbSite.SelectedValue.ToString(), viewFlag_val, newFlag_val, modifyFlag_val, delFlag_val, reportFlag_val, printFlag_val, downloadFlag_val, pInputId, out reMsg, out reData); } } if (reCode == "Y" && reData != "0") { reCnt++; } else { reCnt2++; } } } } MessageBox.Show(wRM.GetString("wSuccess") + "[" + reCnt.ToString() + "], " + wRM.GetString("wFail") + "[" + reCnt2.ToString() + "]"); SetDataBind_gridView1(_codeGrp, _tMenuCd, _sMenuCd); } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuSetAuthSite.cs (Function)::btnSave_Click (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } }
private void SetDataBind_gridView1(string code_grp, string tmenuCd, string smenuCd) { M_WsMenuMainDB.WsMenuMainDB wSvc = null; string reCode = ""; string reMsg = ""; M_WsMenuMainDB.DataSetAuthSiteMemberDB[] getData = null; try { wSvc = new M_WsMenuMainDB.WsMenuMainDB(); wSvc.Url = "http://" + AppInfo.SsWsvcServer2 + "/WebSvc/Sys/Menu/WsMenuMainDB.svc"; wSvc.Timeout = 1000; if (code_grp == "1") { reCode = wSvc.sSetAuthSiteMemberDB(_dbNm, AppInfo.SsSiteCd, tmenuCd, smenuCd, cmbSite.SelectedValue.ToString(), out getData, out reMsg); if (reCode == "Y") { if (getData != null && getData.Length > 0) { dataGridView1.Rows.Clear(); for (int i = 0; i < getData.Length; i++) { dataGridView1.Rows.Add(); dataGridView1.Rows[i].Cells["dgv1_MENU_CD"].Value = getData[i].MENU_CD.ToString(); dataGridView1.Rows[i].Cells["dgv1_NM"].Value = getData[i].MENU_NM.ToString(); dataGridView1.Rows[i].Cells["dgv1_VIEW_FLAG"].Value = getData[i].VIEW_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_NEW_FLAG"].Value = getData[i].NEW_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_MODIFY_FLAG"].Value = getData[i].MODIFY_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_DEL_FLAG"].Value = getData[i].DEL_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_REPORT_FLAG"].Value = getData[i].REPORT_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_PRINT_FLAG"].Value = getData[i].PRINT_FLAG.ToString(); dataGridView1.Rows[i].Cells["dgv1_DOWNLOAD_FLAG"].Value = getData[i].DOWNLOAD_FLAG.ToString(); } SetRowNumber(dataGridView1); } else { dataGridView1.Rows.Clear(); //MessageBox.Show("데이터가 없습니다"); } } } } catch (Exception ex) { logs.SaveLog("[error] (page)::FrmMenuSetAuthSite.cs (Function)::SetDataBind_gridView1 (Detail)::code_grp=[" + code_grp + "], tmenuCd=[" + tmenuCd + "], smenuCd=[" + smenuCd + "]", "Error"); logs.SaveLog("[error] (page)::FrmMenuSetAuthSite.cs (Function)::SetDataBind_gridView1 (Detail)::reMsg=[" + reMsg + "]", "Error"); logs.SaveLog("[error] (page)::FrmMenuSetAuthSite.cs (Function)::SetDataBind_gridView1 (Detail):: " + "\r\n" + ex.ToString(), "Error"); } finally { if (wSvc != null) { wSvc.Dispose(); } } }