예제 #1
0
        private void MainForm_Load(object sender, EventArgs e)
        {
            this.BackgroundImage = Image.FromFile(Application.StartupPath + @"\img\main.jpg");
            //pictureBox1.Image = Image.FromFile(Application.StartupPath + @"\img\main.jpg");
            this.BackgroundImageLayout = ImageLayout.Stretch;

            //获取系统标题栏名称
            xtBiz  xtbiz  = new xtBiz();
            string xtxsmc = xtbiz.GetXtCsz("Xtdlxsmc");

            if (xtxsmc.Trim() == "" || xtxsmc == null)
            {
                xtxsmc = "体检管理信息平台";
            }

            if (!Program.sfzc)
            {
                Form frm = new Form_reg();
                frm.ShowDialog();
            }
            else
            {
                this.Text = "【" + Program.yljgmc + "】" + xtxsmc;
            }
            //toolStripStatusLabel1.Text = toolStripStatusLabel1.Text + Program.ksmc;
            toolStripStatusLabel2.Text = toolStripStatusLabel2.Text + Program.username;
            toolStripStatusLabel3.Text = toolStripStatusLabel3.Text + DateTime.Now;
            addMenu(this);
        }
예제 #2
0
        private void Form_zywj_Load(object sender, EventArgs e)
        {
            if (str_ctlx == "CMP")
            {
                lbl_ksjs.Visible = false;
                txt_ksjs.Visible = false;
                bt_ok.Visible    = false;
            }
            if (!Program.sfzc)
            {
                Form_reg frm = new Form_reg();
                frm.ShowDialog();
            }

            BindData();

            if (str_tjbh != "")
            {
                TJDJB_DataBind(str_tjbh, str_tjcs);
                TJ_ZYJLMX_DataBind(str_tjbh, str_tjcs);
                TJ_ZYJL_DataBind(str_tjbh, str_tjcs);

                if (str_sumover == "2")
                {
                    foreach (Control control in tabControl.TabPages[TabPages - 1].Controls)
                    {
                        if (control.Name == "Button" + TabPages.ToString())
                        {
                            control.Text = "打印(&P)";
                            if (Convert.ToInt32(str_dycs) > 0)//如果打印过禁止打印
                            {
                                control.Enabled = false;
                            }
                        }
                    }
                }
            }
        }
예제 #3
0
        void item2_Click(object sender, EventArgs e)
        {
            Form frm = new Form_reg();

            frm.ShowDialog();
        }