Click here to Skip to main content
11,705,762 members (51,410 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>

Click Button1
Click Button1
Click Button1
you will find TextBox1.Text is changed,what makes it change?
Posted 13-Oct-12 16:51pm
Comments
Wes Aday at 13-Oct-12 23:17pm
   
Do you think that it's possible that whatever happens is located in "Button1_Click"?
happy_daily at 14-Oct-12 8:17am
   
If you click button,you will find TextBox1.Text changes to ',', with the button1_chlick() has nothing,just try
Wes Aday at 14-Oct-12 8:33am
   
No.... no it does not.
happy_daily at 14-Oct-12 9:23am
   
Are u sure? Do u try it? I have tried it on different computers, and find the textbox1.text changed strangely.
happy_daily at 14-Oct-12 8:18am
   
If you click button,you will find TextBox1.Text changes to ',', with the button1_chlick() has nothing,just try

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Sounds like you are asking how does textbox text change when button is clicked.

Well, when button is clicked, page postback happens and event defined if occured executes. Whatever is mentioned in the event method, code executes and one can see the changes on page rendered.

To know the full inner details on how and what happens page flow wise, read:
Complete Lifecycle of an ASP.Net page and controls[^]
ASP.NET Application and Page Life Cycle[^]
MSDN: ASP.NET Page Life Cycle Overview[^]
  Permalink  

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

  Print Answers RSS
0 OriginalGriff 213
1 Sergey Alexandrovich Kryukov 170
2 Inimicos 60
3 ProgramFOX 50
4 Richard MacCutchan 45
0 OriginalGriff 9,037
1 Sergey Alexandrovich Kryukov 8,417
2 CPallini 5,189
3 Maciej Los 4,726
4 Mika Wendelius 3,626


Advertise | Privacy | Mobile
Web01 | 2.8.150819.1 | Last Updated 14 Oct 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100