public static TempEmpInsert GetInstance() { if (weiform == null || weiform.IsDisposed) { weiform = new TempEmpInsert(); } return(weiform); }
private void barButtonItem新增_ItemClick(object sender, ItemClickEventArgs e) { bool right = TempEmpUpdate.ModifyRight(); if (right) { TempEmpInsert Frm = TempEmpInsert.GetInstance(); Frm.TopLevel = false; Frm.Parent = this; Frm.Show(); Frm.BringToFront(); } else { MessageBox.Show("没有权限!"); } }