Пример #1
0
 private void b_new_Click(object sender, EventArgs e)
 {
     common_file.common_app.get_czsj();
     Xxtsz.Xxfmx_zbzd_add_edit Xxfmx_zbzd_add_edit_new = new Xxfmx_zbzd_add_edit(this);
     Xxfmx_zbzd_add_edit_new.StartPosition  = FormStartPosition.CenterScreen;
     Xxfmx_zbzd_add_edit_new.judge_add_edit = common_file.common_app.get_add;
     Xxfmx_zbzd_add_edit_new.ShowDialog();
     Cursor.Current = Cursors.Default;
 }
Пример #2
0
        private void b_amend_Click(object sender, EventArgs e)
        {
            common_file.common_app.get_czsj();
            if (dg_xfmx_lkzd.CurrentRow != null)
            {
                int i = dg_xfmx_lkzd.CurrentRow.Index;
                if (DS_Xxfmx.Tables[0].Rows[i]["id"].ToString() != "")
                {
                    Xxtsz.Xxfmx_zbzd_add_edit Xxfmx_zbzd_add_edit_new = new Xxfmx_zbzd_add_edit(this);

                    Xxfmx_zbzd_add_edit_new.StartPosition  = FormStartPosition.CenterScreen;
                    Xxfmx_zbzd_add_edit_new.judge_add_edit = common_file.common_app.get_edit;
                    Xxfmx_zbzd_add_edit_new.Xxfxr_id       = DS_Xxfmx.Tables[0].Rows[i]["id"].ToString();
                    Xxfmx_zbzd_add_edit_new.tB_bz.Text     = DS_Xxfmx.Tables[0].Rows[i]["bz"].ToString();
                    Xxfmx_zbzd_add_edit_new.tB_zbnr.Text   = DS_Xxfmx.Tables[0].Rows[i]["zbnr"].ToString();
                    Xxfmx_zbzd_add_edit_new.strissh        = DS_Xxfmx.Tables[0].Rows[i]["is_sh"].ToString();
                    string is_sh = DS_Xxfmx.Tables[0].Rows[i]["is_sh"].ToString();

                    if (DS_Xxfmx.Tables[0].Rows[i]["is_sh"].ToString() != null && DS_Xxfmx.Tables[0].Rows[i]["is_sh"].ToString() != "")
                    {
                        if (is_sh == common_file.common_app.is_sh)
                        {
                            Xxfmx_zbzd_add_edit_new.Cb_is_tj_kc.Visible = false;
                        }

                        else
                        {
                            Xxfmx_zbzd_add_edit_new.Cb_is_tj_kc.Visible = true;
                            Xxfmx_zbzd_add_edit_new.Cb_is_tj_kc.Checked = false;
                        }
                    }
                    Xxfmx_zbzd_add_edit_new.ShowDialog();
                }
                Cursor.Current = Cursors.Default;
            }
        }