Exemplo n.º 1
0
        private void btn_Click(object sender, EventArgs e)
        {
            Button btn = (Button)sender;

            switch (btn.Name)
            {
            case "delete":
                //MessageBox.Show(BNo);
                api = new WebAPI();
                ht  = new Hashtable();
                ht.Add("bNo", BNo);
                if (!api.Post(Program.serverUrl + "delete/Note", ht))
                {
                    MessageBox.Show("삭제 실패");
                    break;
                }
                MessageBox.Show("삭제되었습니다.");
                NoticeInfo_porc(cNo[0]);
                break;

            case "write":
                detail_Info = new Detail_Info();
                detail_Info.ShowDialog();
                Dash_lv.Items.Clear();
                break;

            default:
                break;
            }
        }
Exemplo n.º 2
0
        private void lv_Click(object sender, MouseEventArgs e)
        {
            ListView lv = (ListView)sender;

            lv.FullRowSelect = true;
            ListView.SelectedListViewItemCollection itemGroup = lv.SelectedItems;

            for (int i = 0; i < itemGroup.Count; i++)
            {
                ListViewItem item = itemGroup[i];
                Subject = item.SubItems[2].Text;
                //MessageBox.Show(Subject);
                Content = item.SubItems[3].Text;
                //MessageBox.Show(Content);
                //MessageBox.Show(item.SubItems[0].Text);
                bNo         = item.SubItems[0].Text;
                detail_Info = new Detail_Info(bNo, nTitle, Subject, Content);
                detail_Info.ShowDialog();
            }
        }