using System; using System.Collections; using System.Configuration; using System.Data; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Data.SqlClient; public partial class Show : System.Web.UI.Page { SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["CMSConnectionString"].ToString()); int muslim; protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { // muslim = Convert.ToInt16(Request.QueryString["id"].ToString()); lblMuslim.Text = "تفاصيل عن " + Request.QueryString["Name"].ToString(); Page.Title = "تفاصيل عن " + Request.QueryString["Name"].ToString(); loadData(); } } private void loadData() { SqlCommand cmd = new SqlCommand("Select * From Taqim where Muslim_Code=" + Convert.ToInt16(Request.QueryString["Code"].ToString()) + "", con); if (con.State == ConnectionState.Closed) con.Open(); SqlDataReader dr = cmd.ExecuteReader(); dr.Read(); if (dr.HasRows) { taha2.Visible = true; string alFataha, AlNas, AlFalaq, AlEslash, Prayer, Prayer_slam, Prayer_roqa, Prayer_Sogud, Prayer_Ibrahim, Prayer_woduaa, aqeda_1, aqeda_2, aqeda_3, aqeda_4; alFataha = dr[2].ToString(); if (alFataha == "False") CHBalFataha.Checked = false; else CHBalFataha.Checked = true; AlNas = dr[3].ToString(); if (AlNas == "false") CHBAlNas.Checked = false; else CHBAlNas.Checked = true; AlFalaq = dr[4].ToString(); if (AlFalaq == "false") CHBAlFalaq.Checked = false; else CHBAlFalaq.Checked = true; AlEslash = dr[5].ToString(); if (AlEslash == "False") CHBAlEslash.Checked = false; else CHBAlEslash.Checked = true; Prayer = dr[6].ToString(); if (Prayer == "1") CHBPrayer1.Checked = true; if (Prayer == "2") CHBPrayer2.Checked = true; if (Prayer == "3") CHBPrayer3.Checked = true; Prayer_woduaa = dr[11].ToString(); if (Prayer_woduaa == "1") CHBPrayer_woduaa1.Checked = true; if (Prayer == "2") CHBPrayer_woduaa2.Checked = true; if (Prayer == "3") CHBPrayer_woduaa3.Checked = true; Prayer_slam = dr[7].ToString(); if (Prayer_slam == "False") CHBPrayer_slam.Checked = false; else CHBPrayer_slam.Checked = true; Prayer_roqa = dr[8].ToString(); if (Prayer_roqa == "False") CHBPrayer_roqa.Checked = false; else CHBPrayer_roqa.Checked = true; Prayer_Sogud = dr[9].ToString(); if (Prayer_Sogud == "False") CHBPrayer_Sogud.Checked = false; else CHBPrayer_Sogud.Checked = true; Prayer_Ibrahim = dr[10].ToString(); if (Prayer_Ibrahim == "False") CHBPrayer_Ibrahim.Checked = false; else CHBPrayer_Ibrahim.Checked = true; aqeda_1 = dr[12].ToString(); if (aqeda_1 == "False") CHBaqeda_1.Checked = false; else CHBaqeda_1.Checked = true; aqeda_2 = dr[13].ToString(); if (aqeda_2 == "False") CHBaqeda_2.Checked = false; else CHBaqeda_2.Checked = true; aqeda_3 = dr[14].ToString(); if (aqeda_3 == "False") CHBaqeda_3.Checked = false; else CHBaqeda_3.Checked = true; aqeda_4 = dr[15].ToString(); if (aqeda_4 == "False") CHBaqeda_4.Checked = false; else CHBaqeda_4.Checked = true; dr.Close(); con.Close(); } dr.Close(); con.Close(); } protected void BtnAdd0_Click(object sender, EventArgs e) { muslim = Convert.ToInt16(Request.QueryString["Code"].ToString()); string tahahaha = Request.QueryString["char"].ToString(); Response.Redirect("Daily.aspx?char=" + tahahaha + "&Code=" + muslim); ; } }