try:Page_Load(...)
{
....
  if(!IsPostBack)
  {
     atextbox.Text="first test";
     btextbox.Text="second test";
  }
.....
}

解决方案 »

  1.   

    Actually, thing is not easy. Originally I did not put the 
    atextbox.Text="first test" 
    btextbox.Text="second test" 
    Page_Load{}
    that way. I totally agree withe what you said.
    All what I did is like this
    Page_Load()
    {}
    private void uploaddata()
    {// type the text in the textbox through the interface
    //and upload them into database
    //basically like the following
    atextbox.Text="first test";
    btextbox.Text="second test";
    .......}Then through a button to call the following functionprivate void upatedata()
    {
     atextbox.Text="New first Data";
    btextbox.Text="New second Data";
    this.myDatabinding();
    .......
    }private void myDatabinding()
    {
    ///bind the data in a database into a datagrid.
    ......
    }
    the texts in the two textbox do not change after I update the data.Any idea what this might go wrong.
    I am sorry I did not pay attention to the stuff I wrote the first time.
    Thank you  niwalker and  hbxtx
      

  2.   

    Did you set EnabelViewState to true which on the page's properties window?