Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RadioButton AutoPostBack Problem

Status
Not open for further replies.

Gorkem

Programmer
Jun 18, 2002
259
CA
Hi All,

I have a radio button inside of a repeater. I am trying to do an AutoPostBack when a user clicks on a particular radiobutton and run a routine to see which one was selected. The AutoPostBack does reload the page, however my OnCheckChanged event is not firing.

My radiobutton code is as follows:
Code:
<asp:RadioButton EnableViewState="false" OnCheckedChanged="RadioButton_OnCheckChanged" GroupName='Grp1' value='<%# FlightID %>' AutoPostBack="false" runat="server" ID="SelFlight1" Width=15 Text=" " />

Any help would be appreciated!

Cheers,

G.



Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
Hi JBenson!

Thanks for your speedy reply!

There is currently no code in there, I have put a debug stop at the begining of the event routine to ensure that it does indeed fire.. but it is not stopping at that spot.

in any case, the routine is:
Code:
 protected void RadioButton_OnCheckChanged(object sender, EventArgs e)
    {

    }

Cheers,

G.



Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
Oh yeah.. LOL.. I turned that off for some other testing.. that normally says TRUE

Cheers,

G.





Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
Good Luck???


Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
is it not possible to do what I need to do?

Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
Yes, set it back to True...


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
I did.. still not working..

Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
I was just wishing you luck.. I was not being sarcastic :)

You traced through the code and it does not hit the event?
 
Yeah.. it hits the Page_Load postback.. but not the event.. I even lose the EditItem in my datalist after postback.



Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
My guess is that you are not checking for a Page.IsPostBack on your page load event and are re-populating the repeater each time and therefore the event can't fire...


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
well thats about 50% true..

I DO have a isPostBack check.. however, the repeater is inside of a nested repeater which is part of a datalist.. the datalist is updated each time, so the EnableViewState="false".. Could this be the problem?

Cheers,

G.



Oxigen - Next generation business solutions
-----------------------------
Components/Tools/Forums/Software/Web Services
 
Yes I think that as the state isn't being kept, it will be rebound to it's original value and therefore won't fire it's event as it is reset when the page loads.


____________________________________________________________

Need help finding an answer?

Try the Search Facility or read FAQ222-2244 on how to get better results.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top