locked
Should SqlDataSource Selected Event always fire? RRS feed

  • Question

  • User-39209296 posted

    Hi

     In the page load of my webpage I call a databind for a gridview.

    It generally calls this event handler :

    protected void SqlDataSource1_Selected(object sender, SqlDataSourceStatusEventArgs e)

     

    However sometimes (seemingly randomly) it doesn't.

    Any ideas?

    Thanks

     

    protected void Page_Load(object sender, EventArgs e)

    {

    ...

    if (searchText != "")

        SqlDataSource1.SelectParameters["search"].DefaultValue = searchText;

    else{

    SqlDataSource1.SelectParameters["search"].DefaultValue = "";

    GridView1.DataBind();

    }

    Wednesday, May 2, 2007 4:47 AM

Answers

All replies