예제 #1
0
        public void open_hysj()  //会员升级页
        {
            common_file.common_app.get_czsj();
            if (dg_count > 0 && dg_hygl.Rows[0].Cells["id"].Value != null && dg_hygl.Rows[0].Cells["id"].Value.ToString() != string.Empty)
            {
                int i = dg_hygl.CurrentRow.Index;

                DataRowView dgr = dg_hygl.CurrentRow.DataBoundItem as DataRowView;
                i = DS_Hygl.Tables[0].Rows.IndexOf(dgr.Row);


                if (i > -1 && i < dg_count)//当前行为内容行
                {
                    //int id = Convert.ToInt32(dg_hygl.Rows[i].Cells["id"].Value);
                    Hhygl.Hhygl_hysj Hhygl_hysj_new = new Hhygl_hysj(this);
                    Hhygl_hysj_new.StartPosition = FormStartPosition.CenterScreen;

                    Hhygl_hysj_new.Hhygl_id        = DS_Hygl.Tables[0].Rows[i]["id"].ToString();
                    Hhygl_hysj_new.tB_hykh_bz.Text = DS_Hygl.Tables[0].Rows[i]["hykh_bz"].ToString();
                    Hhygl_hysj_new.tB_krxm.Text    = DS_Hygl.Tables[0].Rows[i]["krxm"].ToString();
                    Hhygl_hysj_new.tB_hyrx.Text    = DS_Hygl.Tables[0].Rows[i]["hyrx"].ToString();
                    Hhygl_hysj_new.tB_hyjf.Text    = DS_Hygl.Tables[0].Rows[i]["hyjf"].ToString();
                    //Hhygl_hysj_new.tB_hykh.Text = DS_Hygl.Tables[0].Rows[i]["hykh"].ToString();
                    Hhygl_hysj_new.strhykh = DS_Hygl.Tables[0].Rows[i]["hykh"].ToString();
                    Hhygl_hysj_new.ShowDialog();
                }
            }
            Cursor.Current = Cursors.Default;
        }
예제 #2
0
        private void b_sj_Click(object sender, EventArgs e)
        {
            if (common_file.common_roles.get_user_qx("B_hygl__sj", common_file.common_app.user_type) == false)
            {
                return;
            }
            if (Hhygl_id != "" && hykh != "")
            {
                //int id = Convert.ToInt32(dg_hygl.Rows[i].Cells["id"].Value);
                Hhygl.Hhygl_hysj Hhygl_hysj_new = new Hhygl_hysj();
                Hhygl_hysj_new.StartPosition = FormStartPosition.CenterScreen;

                Hhygl_hysj_new.Hhygl_id        = Hhygl_id;
                Hhygl_hysj_new.tB_hykh_bz.Text = tB_hykh_bz.Text.Trim();
                Hhygl_hysj_new.tB_krxm.Text    = tB_krxm.Text.Trim();
                Hhygl_hysj_new.tB_hyrx.Text    = cB_hyrx.Text.Trim();
                Hhygl_hysj_new.tB_hyjf.Text    = tB_hyjf.Text.Trim();
                Hhygl_hysj_new.strhykh         = hykh;
                Hhygl_hysj_new.ShowDialog();
            }
            Cursor.Current = Cursors.Default;
        }