Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Trying to programatically change a TextBox
Message
De
20/02/2005 14:05:52
Nancy Folsom
Pixel Dust Industries
Washington, États-Unis
 
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00988694
Message ID:
00988699
Vues:
44
>Hi.
>I have a form, with a control on it (txtName) Databinded to a datatset, and if I amend the name on the form, it all works fine and is saved back to the table.
>
>However the following is happening:
>I have a button ,and on it's Click event the following code:
> this.txtName = 'This name has been changed";
>When I click on the button, it does change it on the screen, but when I save the Dataset, the Database does not get changed !!
>
>I would have thought, because the text box is bound to the Dataset, and because it also displays on screen when I chage it, that it should be saved back to the table .
>
>Any body any idead of what I am doing wrong ?
>

Databinding isn't roundtrip. Rick Strahl has a white paper about this. If you can't find it on www.west-wind.com, post back and I'll hunt it up. I don't recall the details. I found it after I'd already dealt with the same issue, but his paper is well-written, as always.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform