Saturday, March 24, 2012

why some controls must set autopostback property to be true?

why need to set autopostback property to be true?? I know autopostback event
means to send the form to the server automatically.

I tried checkbox, checkbox list, radio button, and radio button list, and
they all need to set autopostback property to be true, in order to make the
event of the control fires.

I know this is the must, but I dont know why. Please advise!

Thanks!only submit buttons (asp image and command buttons) do a postback on theri
own. all other controls need call a javascript routine that does the actual
postback.

1) if client scripting is turned off (security setting), these controls will
not postback. you need to be aware that autopostback is just a hint, not a
guarantee.

2) the postback is very costly, so the default is none, though you could
make a case that the IDE should set if you attach an event handler.

-- bruce

"Matthew Louden" <mattloude@.hotmail.com> wrote in message
news:OFmlTfXrDHA.2536@.tk2msftngp13.phx.gbl...
> why need to set autopostback property to be true?? I know autopostback
event
> means to send the form to the server automatically.
> I tried checkbox, checkbox list, radio button, and radio button list, and
> they all need to set autopostback property to be true, in order to make
the
> event of the control fires.
> I know this is the must, but I dont know why. Please advise!
> Thanks!
>

0 comments:

Post a Comment