Binding a StatusBar Panel Text property - Solution?!

M

Matt

I've found that the StatusBar Panel object does not have a DataBindings
property which doesn't help if you want to do such a thing.

Searching the web and these news groups didn't present me with an
answer so I thought I'd post what I came up with to help others.

Add another control to your form that does have a DataBindings & Text
property, I used a Label.
Bind that contol to what ever you wish to display.
In the TextChanged event for the control that is now bound, set the
Text property of the StausBar Panel to whatever the control has just
changed to.
Make the extra control invisible.

Hope it helps,

Matt
 
M

Matt

Ooops, I've just found that making the extra control (Label) invisible
prevents the TextChanged event from firing.

I'll have to hide it somewhere :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top