Results 1 to 5 of 5

Thread: [RESOLVED] No underline on hot keys

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2005
    Posts
    394

    Resolved [RESOLVED] No underline on hot keys

    I have acommand button that I want to use alt+some key to fire the on_click event of that button. At design time, I am assigning the button text property as &Test. This underlines the T in the design view but when I run the app, the T is no longer underlined. The alt+T fires the on_click event but the user would not know that this is available without the underline. Am I missing a property somwhere?

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: No underline on hot keys

    That is caused by a Windows setting. You have to press the Alt key for the underlines to become visible, which is reasonable given that you have to press the Alt key to use the shortcut. You can turn this feature on and off within Windows, although I can't for the life of me remember where, but your app has no control over it as it is a system-wide setting.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3
    Fanatic Member dannymking's Avatar
    Join Date
    Jul 2005
    Location
    Darlington, North East UK
    Posts
    677

    Re: No underline on hot keys

    Is your control's height sufficient to display this??

    To switch the hidden property back on you need to open control panel, Display, Appearance and then Effects it's the last checkbox in this screen.
    Last edited by dannymking; Jul 26th, 2005 at 09:01 AM.
    Danny

    Never Think Impossible

    If you find my answer helpful then please add to my reputation

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: No underline on hot keys

    Found it. Control Panel -> Display, select the Appearance tab and click the Effects button. The option is "Hide underlined letters for keyboard navigation until I press the Alt key". I imagine that you could change a registry setting to affect this, but if the user wants to change it they should be allowed to change it themselves.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  5. #5

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2005
    Posts
    394

    Re: [RESOLVED] No underline on hot keys

    Got it. Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width