private void button3_Click(object sender, EventArgs e) { try { hsnreport b2c = new hsnreport(master, tabControl); master.AddNewTab(b2c); } catch { } }
private void button3_Click(object sender, EventArgs e) { try { userrights = conn.getdataset("Select * from UserRights where isactive=1 and uid='" + Master.userid + "'"); if (userrights.Rows.Count > 0) { if (userrights.Rows[41]["a"].ToString() == "True") { hsnreport b2c = new hsnreport(master, tabControl); master.AddNewTab(b2c); } else { MessageBox.Show("You Don't Have Permission to View"); return; } } } catch { } }