Ejemplo n.º 1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         var obj        = new OperationFunctions();
         var listOfData = obj.GetScanIds();
         drpScanList.DataSource     = listOfData;
         drpScanList.DataTextField  = "ScanName";
         drpScanList.DataValueField = "ScanId";
         drpScanList.DataBind();
     }
     (this.Master.FindControl("lblLoginName") as Label).Text     = Session["UserName"] as string;
     (this.Master.FindControl("hypLogOut") as HyperLink).Visible = true;
 }
Ejemplo n.º 2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         var obj        = new OperationFunctions();
         var listOfData = obj.GetScanIds();
         drpScanList.DataSource     = listOfData;
         drpScanList.DataTextField  = "ScanName";
         drpScanList.DataValueField = "ScanId";
         drpScanList.DataBind();
     }
     if (Session["IsAdmin"] != null)
     {
         Menu mnuControl = this.Master.FindControl("menuMaster") as Menu;
         if (!((bool)Session["IsAdmin"]))
         {
             mnuControl.Items[0].Enabled = false;
             mnuControl.Items[3].Enabled = false;
         }
     }
     (this.Master.FindControl("lblLoginName") as Label).Text     = Session["UserName"] as string;
     (this.Master.FindControl("hypLogOut") as HyperLink).Visible = true;
 }