471,305 Members | 1,522 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,305 software developers and data experts.

problem showing focus on a button

Hi,
From reading something months ago, I've been under the impression that
saying button1.Focus() is enough to focus on the button and highlight it (the
dotted box). If this is true, I don't know what's wrong with my version, but
it doesn't work. In certain circumstances, when a button is definitely
focused on, you wouldn't be able to tell so from looking at the screen (the
dotted box isn't there so it looks like nothing's focused on). I've been
coming up with interesting ways around this, but the current situation is
proving challenging, and I can't imagine there isn't some simple way to force
the dotted line to appear. So, is there any manual way to say to highlight
this button?
Thanks so much!!!!!
Mel
Nov 28 '05 #1
1 1314
melanieab wrote:
Hi,
From reading something months ago, I've been under the impression that
saying button1.Focus() is enough to focus on the button and highlight it (the
dotted box). If this is true, I don't know what's wrong with my version, but
it doesn't work. In certain circumstances, when a button is definitely
focused on, you wouldn't be able to tell so from looking at the screen (the
dotted box isn't there so it looks like nothing's focused on). I've been
coming up with interesting ways around this, but the current situation is
proving challenging, and I can't imagine there isn't some simple way to force
the dotted line to appear. So, is there any manual way to say to highlight
this button?
Thanks so much!!!!!
Mel


In my program I have the button change color when it receives focus. To
accomplish this I made my own button class and overrode the OnFocus and
LostFocus events but that was cause I wanted it everywhere in my
program. If you just need it for one button then handle the onfocus event.

Chris
Nov 28 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Paul Thompson | last post: by
5 posts views Thread by Martin | last post: by
2 posts views Thread by Tim Frawley | last post: by
reply views Thread by A.J | last post: by
4 posts views Thread by Heinrich Wolf | last post: by
3 posts views Thread by jan.loucka | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.