예제 #1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["username"] == null)
        {
            Response.Redirect("~/Login.aspx");
        }
        if (!IsPostBack)
        {
            DataSet ds3 = BloodTypeBusinessLayer.ShowBloodType();
            DataSet ds4 = blood.ShowAllBloodGroup();
            BindDDL(ddlBloodType, ds3, "TypeName", "BloodTypeID");
            BindDDL(ddlBloodGroup, ds4, "BloodGroup", "BloodGroupID");
            org.Username = Session["username"].ToString();

            DataSet ds = new DataSet();
            ds        = org.GetAccountId();
            AcId      = ds.Tables[0].Rows[0][0].ToString();
            org.Orgid = int.Parse(AcId);

            DataSet ds2 = new DataSet();
            ds2              = org.ShowOrganizationAllDetail();
            txtName.Text     = ds2.Tables[0].Rows[0][0].ToString();
            txtMail.Text     = ds2.Tables[0].Rows[0][1].ToString();
            txtPhone.Text    = ds2.Tables[0].Rows[0][2].ToString();
            txtCountry.Text  = ds2.Tables[0].Rows[0][3].ToString();
            txtState.Text    = ds2.Tables[0].Rows[0][4].ToString();
            txtCity.Text     = ds2.Tables[0].Rows[0][5].ToString();
            txtLocation.Text = ds2.Tables[0].Rows[0][6].ToString();
        }
    }
    protected void Page_Load(object sender, EventArgs e)

    {
        if (!IsPostBack)
        {
            //ViewState["Password"] = txtPassword.Text;

            DataSet ds  = AddCountry.GetCountryName();
            DataSet ds1 = BloodTypeBusinessLayer.ShowBloodType();
            DataSet ds2 = blood.ShowAllBloodGroup();
            BindDDL(ddlCountry, ds, "CountryName", "CountryID");
            ddlCountry.Items.Insert(0, "---Select---");
            BindDDL(ddlBloodType, ds1, "TypeName", "BloodTypeID");
            BindDDL(ddlBloodGroup, ds2, "BloodGroup", "BloodGroupID");
        }
    }
예제 #3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!IsPostBack)
     {
         DataSet ds = new DataSet();
         ds = AddCountry.GetCountryName();
         BindDDL(ddlCountry, ds, "CountryName", "CountryID");
         ddlCountry.Items.Insert(0, "---Select---");
         DataSet ds1 = BloodTypeBusinessLayer.ShowBloodType();
         DataSet ds2 = group.ShowAllBloodGroup();
         BindDDL(ddlBloodType, ds1, "TypeName", "BloodTypeID");
         ddlBloodType.Items.Insert(0, "---Select---");
         BindDDL(ddlBloodGroup, ds2, "BloodGroup", "BloodGroupID");
         ddlBloodGroup.Items.Insert(0, "---Select---");
     }
 }
예제 #4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["username"] == null)
        {
            Response.Redirect("~/Login.aspx");
        }
        if (!IsPostBack)
        {
            DataSet ds = AddCountry.GetCountryName();
            BindDDL(ddlCountry, ds, "CountryName", "CountryID");
            ddlCountry.Items.Insert(0, "---Select---");
            DataSet ds1 = BloodTypeBusinessLayer.ShowBloodType();
            DataSet ds2 = blood.ShowAllBloodGroup();
            BindDDL(ddlBloodType, ds1, "TypeName", "BloodTypeID");
            BindDDL(ddlBloodGroup, ds2, "BloodGroup", "BloodGroupID");

            DataSet ds3  = new DataSet();
            string  Acid = Session["Acid"].ToString();
            user.Accountid   = int.Parse(Acid);
            ds3              = user.GetPersonalDetail();
            ViewState["Url"] = ds3.Tables[0].Rows[0][15].ToString();
        }
        LinkButton4.Attributes.Add("onclick", "javascript:showImg();");
        LinkButton4.Attributes.Add("target", "");

        string strScript;

        strScript  = "<script>function showImg() {";
        strScript += "var mywin=window.open('','Image','top=20,left=10,width=500,height=300,scrollbars=yes,resizable=yes,toolbar=no');";
        strScript += "mywin.document.write('<title>BDA</title>');";
        // strScript += "mywin.document.write('<img src=\"" + "../" + ConfigurationManager.AppSettings["MemberImage"].Replace("\\", "/") + ViewState["MemberIMAGE"].ToString() + "\">');";26005.jpg
        strScript += "mywin.document.write('<img src=\"" + "Images/" + ViewState["Url"].ToString() + "\">');";
        //  strScript += "mywin.document.write('<img src=\"" + "Donor/Images/" + "SFairytopia-Mermaidia-She.jpg" + "\">');";
        strScript += "mywin.focus();}</script>";
        Page.RegisterStartupScript("StartUp", strScript);
    }
예제 #5
0
 public void ShowBloodType()
 {
     GridView1.DataSource = BloodTypeBusinessLayer.ShowBloodType();
     GridView1.DataBind();
 }