Exemplo n.º 1
0
    protected void lnkview_Click(object sender, EventArgs e)
    {
        //Response.Redirect("~/AllBlogs.aspx");GetBlogss
        System.Web.UI.ScriptManager.RegisterStartupScript(this, this.GetType(), "HideMyAwesomeUserControl", "$('#divDeletesucess').hide();$('#divSuccess').hide(); ", true);
        DataTable dtSub = new DataTable();

        objblogdo.intAddedBy = Convert.ToInt32(ViewState["UserID"]);
        dtSub = objblogda.GetDataTable(objblogdo, DA_NewBlogs.Blog.GetBlogss);
        if (dtSub.Rows.Count > 0)
        {
            lnlView.Visible       = false;
            RepPopPost.DataSource = dtSub;
            RepPopPost.DataBind();
        }
        else
        {
            RepPopPost.DataSource = null;
            RepPopPost.DataBind();
            lnlView.Visible = false;
        }
        ScriptManager.RegisterStartupScript(this, this.GetType(), "chosen", "createChosen();", true);

        if (Request.UserAgent.Contains("Mobi"))
        {
            ScriptManager.RegisterStartupScript(this, this.GetType(), "Acsi", "showRight();", true);
            ScriptManager.RegisterStartupScript(this, this.GetType(), "Asi", "setActive();", true);
        }
        divShomore.Attributes["class"] = "text-center";
    }
Exemplo n.º 2
0
    private void BindPosts()
    {
        DataTable dtSub = new DataTable();

        objblogdo.intAddedBy = Convert.ToInt32(ViewState["UserID"]);
        dtSub = objblogda.GetDataTable(objblogdo, DA_NewBlogs.Blog.GetAllBlogsPost);
        if (dtSub.Rows.Count > 0)
        {
            RepPopPost.DataSource = dtSub;
            RepPopPost.DataBind();
        }
        else
        {
            RepPopPost.DataSource = null;
            RepPopPost.DataBind();
            lnlView.Visible = false;
        }
    }
Exemplo n.º 3
0
    private void BindComments()
    {
        DataTable dtSub = new DataTable();

        objblogdo.intAddedBy = Convert.ToInt32(ViewState["UserID"]);
        objblogdo.intBlogId  = Convert.ToInt32(ViewState["intBlogId"]);
        dtSub = objblogda.GetDataTableComment(objblogdo, DA_NewBlogs.BlogCommnet.GetByBlog);
        if (dtSub.Rows.Count > 0)
        {
            RepPopPost.DataSource = dtSub;
            RepPopPost.DataBind();
        }
        else
        {
            RepPopPost.DataSource = null;
            RepPopPost.DataBind();
        }
    }