Example #1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         Business.themess themess = new Business.themess();
         Repeater1.DataSource = themess.Get("");
         Repeater1.DataBind();
         themess = null;
     }
 }
Example #2
0
        protected void Repeater1_ItemCommand(object source, RepeaterCommandEventArgs e)
        {
            string Id = e.CommandName;

            Business.themess themess = new Business.themess();
            themess.Delete(Id);
            Repeater1.DataSource = themess.Get("");
            Repeater1.DataBind();
            themess = null;
        }
Example #3
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!Page.IsPostBack)
     {
         if ((string)Session["UserId"] != null)
         {
             Business.themess themess = new Business.themess();
             Repeater1.DataSource = themess.Get(string.Format(" and userid ='{0}'", (string)Session["UserId"]));
             Repeater1.DataBind();
             themess = null;
         }
         else
         {
             Response.Redirect("login.aspx");
         }
     }
 }