Beispiel #1
0
 public void ss()
 {
     Model.user mod = new Model.user();
     mod.username = TextBox3.Text;
     BLL.adminuser blls = new BLL.adminuser();
     int i = blls.coun(mod);
     AspNetPager1.RecordCount = i;
     AspNetPager1.PageSize = 5;
 }
Beispiel #2
0
    public void ss()
    {
        Model.user mod = new Model.user();
        mod.username = TextBox3.Text;
        BLL.adminuser blls = new BLL.adminuser();
        int           i    = blls.coun(mod);

        AspNetPager1.RecordCount = i;
        AspNetPager1.PageSize    = 5;
    }
Beispiel #3
0
    protected void Button1_Click(object sender, EventArgs e)
    {
        if (TextBox3.Text == "")
        {
            Label2.Visible = true;
            Label3.Visible = true;
            GridView1.Visible = false;
            AspNetPager1.Visible = false;
        }
        else
        {
            Label2.Visible = false;
            Label3.Visible = true;
            GridView1.Visible = true;
            AspNetPager1.Visible = true;

            Model.user mod = new Model.user();
            mod.username = TextBox3.Text;
            BLL.adminuser blls = new BLL.adminuser();
            int i = blls.coun(mod);
            AspNetPager1.RecordCount = i;
            AspNetPager1.PageSize = 5;

            Model.user mode = new Model.user();
            mode.username = TextBox3.Text;
            DataSet ds = blls.seu(AspNetPager1.PageSize * (AspNetPager1.CurrentPageIndex - 1), AspNetPager1.PageSize, "user",mod);
            GridView1.DataSource = ds.Tables["user"];
            GridView1.DataBind();
            if (i == 0)
            {
                AspNetPager1.Visible = false;
                Label2.Visible = true;
                Label3.Visible = false;

            }
        }
    }
Beispiel #4
0
    protected void Button1_Click(object sender, EventArgs e)
    {
        if (TextBox3.Text == "")
        {
            Label2.Visible       = true;
            Label3.Visible       = true;
            GridView1.Visible    = false;
            AspNetPager1.Visible = false;
        }
        else
        {
            Label2.Visible       = false;
            Label3.Visible       = true;
            GridView1.Visible    = true;
            AspNetPager1.Visible = true;

            Model.user mod = new Model.user();
            mod.username = TextBox3.Text;
            BLL.adminuser blls = new BLL.adminuser();
            int           i    = blls.coun(mod);
            AspNetPager1.RecordCount = i;
            AspNetPager1.PageSize    = 5;


            Model.user mode = new Model.user();
            mode.username = TextBox3.Text;
            DataSet ds = blls.seu(AspNetPager1.PageSize * (AspNetPager1.CurrentPageIndex - 1), AspNetPager1.PageSize, "user", mod);
            GridView1.DataSource = ds.Tables["user"];
            GridView1.DataBind();
            if (i == 0)
            {
                AspNetPager1.Visible = false;
                Label2.Visible       = true;
                Label3.Visible       = false;
            }
        }
    }