Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Display Count from textbox - MVVM
Message
De
22/10/2011 11:24:07
Timothy Bryan
Sharpline Consultants
Conroe, Texas, États-Unis
 
Information générale
Forum:
ASP.NET
Catégorie:
Windows Presentation Foundation (WPF)
Versions des environnements
Environment:
C# 3.0
OS:
Windows XP SP2
Application:
Desktop
Divers
Thread ID:
01527088
Message ID:
01527098
Vues:
42
>I would consider adding new property CharactersLeft to the ViewModel, binding the label to this property, and changing this property inside the setter of a property that the textboxe's Text is bound to.

That is what I have, but the setter property of the textbox binding does not get used by WPF. There needs to be another way to hook up an event so I have updates from the Texbox changed within a view model.

I can read the length from the bound property easy enough, I just don't know when to read it. I have the label bound to a property that returns the value needed to display in my View Model. Works fine, just doesn't update

I am wondering if there is a way to hook up a binding directly to the textbox element and get length.
Timothy Bryan
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform