Click here to Skip to main content
15,881,831 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a gridview in asp, and in code behind I have the SelectedIndexChanged event. I made some changes to the MasterPage, and now the gridview, when selecting a row, is not firing the SelectIndexChange event but is doing the PostBack to the page.

I know that the gridview calls a javascript __dopostback to select the row. It is possible that I could have deleted somethig from masterpage that is now disabling the gridview selection event?

thank you
Posted

Try putting the code back the way it was, and see if you once again get your events. If you do, then I'd say you pretty much narrowed down the problem.
 
Share this answer
 
Comments
Sandeep Mewara 8-Feb-11 12:32pm    
Comment from OP:
Well I have seen the earlier code and I don-t find anything that could be causing the problem...I am going crazy with this.
This is where source control and version history would have been a time saver. You could have done a comparison to see what changed and could have quickly located the code that may have got accidentally deleted. Not helping you with this one but may be handy to keep this in mind for the future.

[Update]
~~~~~~~~~~~

This is in response to your comment.

See if this SO thread will help you:
http://stackoverflow.com/questions/485390/why-isnt-the-selectedindexchanged-event-firing-from-a-dropdownlist-in-a-gridview[^]
 
Share this answer
 
v2
Comments
Sandeep Mewara 8-Feb-11 12:32pm    
Comment from OP:
Well I have seen the earlier code and I don-t find anything that could be causing the problem...I am going crazy with this.
There are some things that we just don't need to understand. I drag the gridview outside the Panel, and then I put it back, and it worked.

Awww Microsoft...
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900