Steve,
You won't be able to do this. You will need an object that stores the
int, and exposes it as a property, also firing an event when it changes. An
int is a value type, and doesn't have any mechanism to indicate when the
value changes.
Your only choice would be to create an object with a property that
exposes this, and an event that fires (named correctly <property
name>Changed of type EventHandler) when the property changes.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"SteveK" <as***@asdfasdfsd.com> wrote in message
news:%2******************@TK2MSFTNGP10.phx.gbl...
I have a text box and I simply want to bind it to an int variable. I'm
testing how all this stuff works and I wanted to test if I increment the
int, will the textbox update automatically, however I didn't get far cause
I
can't get binding to work with an int OR I should say it wants an object
and
a member..
Any tips or heads-ups?
Thanks-
Steve