TextBox AutoPostBack event not firing correctly

B

Ben Fidge

Hi

I've got a TextBox on my WebForm with it's AutoPostback
set to true, and an event handler created for the
TextChanged event.

I would expect this event to be fired when the user types
any character into the textbox. However, the event is
only firing when the users enters text and THEN moves to
another control on the page.

Is this behaviour by design?

Thanks

Ben Fidge
 
P

Patrice Scribe

AFAIK yes,

It would be far too costly anyway to make a server round trip each time the
user press a key ie the TextChanged event fire when you are reasonably sure
that a sequence of changes is over (ie moving to another control).

Patrice
 
B

Ben Fidge

I totally agree, and took the precaution of switching off
AutoPostBack after the initial event is fired.

Thanks

Ben
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top