Пример #1
0
        private void forwardMessSent(DataGridView tbl, string clmContentMess)
        {
            DataGridViewSelectedRowCollection selectedRows = tbl.SelectedRows;

            if (selectedRows.Count == 1)
            {
                DataGridViewRow row        = selectedRows[0];
                FormCompose     frmCompose = new FormCompose();
                frmCompose.Show();
                frmCompose.txtMessage.Text = row.Cells[clmContentMess].Value.ToString();
            }
            else if (selectedRows.Count > 1)
            {
                MessageBox.Show("Ban chi duoc chon 1 tin nhan de chuyen tiep .");
            }
            else
            {
                MessageBox.Show("Ban phai chon tin nhan de chuyen tiep");
            }
        }
Пример #2
0
        private void replyMessInbox(DataGridView tbl, string clmName)
        {
            DataGridViewSelectedRowCollection selectedRows = tbl.SelectedRows;

            if (selectedRows.Count == 1)
            {
                DataGridViewRow row        = selectedRows[0];
                FormCompose     frmCompose = new FormCompose();
                frmCompose.MdiParent = this.MdiParent;
                frmCompose.Show();
                frmCompose.txtPhoneNumber.Text = row.Cells[clmName].Value.ToString();
            }
            else if (selectedRows.Count > 1)
            {
                MessageBox.Show("Ban chi duoc chon 1 tin nhan de tra loi .");
            }
            else
            {
                MessageBox.Show("Ban phai chon tin nhan de tra loi");
            }
        }