TextBox Changes Do Not Show Up

G

Guest

I am writing an ASP.NET 2.0 application that includes several pages with
textBoxes. In all pages but one changes in the textBoxes can be retrieved
using the Text property of the textBox except one page. One this particular
page the previous Text value always is shown in postback handlers after the
text has been changed. I have tried setting the Autopostback property on the
textBox to true and false and have used the TextChanged event as well. Yet
this box on this page always shows its previous value.

What can be wrong with this textBox and/or page?

Your help will be greatly appreciated.

Thanks,
Eagle
 
M

Marina Levit [MVP]

Are you possibly resetting the text of the textbox in Page_Load or
elsewhere?

"(e-mail address removed)"
 
C

Chip

Most likely, you are filling the textbox using code and that is happening
each time your page is posted back, resetting to the default state. You may
need to look carefully at the process flow and make sure your textbox_fill
routine is not called when posting back.

Chip


"(e-mail address removed)"
 
G

Guest

Take out shotgun, aim it at your foot and pull the trigger! I am doing some
cute stuff with this textBox in the Page_Load event handler. I'll have to
rethink my logic.

Thanks, guys.

Eagle
 

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

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,818
Latest member
Brigette36

Latest Threads

Top