SqlConnection con = new SqlConnection(GZSoft.Web.GZBasic.GetWebConfigString("GZSoftConn"));
string sql = "1=1 ";
if (SQLStr.Trim() != "")
{
sql += SQLStr;
}
SqlDataAdapter dr = new SqlDataAdapter("select * from Basic_View_115Apply where " + sql + " order by " + ddlCompositor.SelectedValue+" "+ddlorderBy.SelectedValue, con);
DataSet ds = new DataSet();
DataSet ds2 = new DataSet();
dr.Fill(ds2);
dr.Fill(ds, 1, 15, "tab1");//前15条
this.gvTab.DataSource = ds.Tables[0];
this.gvTab.DataBind();