|
code
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Shortcut Underlines Don't Show Up With Manifest??I'd never noticed this before, but the underlined shortcuts placed onto
command buttons (like with &Print for Print with the P underscored, indicating a hot key) don't show up on my WinXP PC when running the EXE using a Manifest file for the newer control looks. The shortcuts still work, but no one can see them. What's up with that?? Is there a way to make them show up? I've taken great care to be sure I have shortcuts to my most used functions, but if they don't show, then they're kind of worthless. -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net Try turning on the focus marks with a sneaky message
Public Const WM_CHANGEUISTATE As Long = &H127 Public Const USIF_RESET As Long = 65538 Public Declare Function SendMessageAny Lib "user32" Alias "SendMessageA" (ByVal hWnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long ' COMMENT 'USIF_RESET = ' (LoByte) Const UIS_CLEAR As Integer = &H2 ' + (HiByte) Const UISF_HIDEFOCUS As Integer = &H1 ' In form load event ' For forms where the controls are added dynamically, put this line after the form is built Call SendMessageAny(Me.hWnd, WM_CHANGEUISTATE, USIF_RESET, ByVal 0) This *should* work, I have apps with manifest & buttons with hotkeys and they all show up, I'm moderately certain they didn't until I added this (I could be wrong about that) Regards Dave O. Show quoteHide quote "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote in message news:%23luw1BrkJHA.3760@TK2MSFTNGP03.phx.gbl... > I'd never noticed this before, but the underlined shortcuts placed onto > command buttons (like with &Print for Print with the P underscored, > indicating a hot key) don't show up on my WinXP PC when running the EXE > using a Manifest file for the newer control looks. > > The shortcuts still work, but no one can see them. > > What's up with that?? Is there a way to make them show up? I've taken > great care to be sure I have shortcuts to my most used functions, but if > they don't show, then they're kind of worthless. > > -- > Regards, > > Rick Raisley > heavymetal-A-T-bellsouth-D-O-T-net > >
Show quote
Hide quote
"Dave O." <nob***@nowhere.com> wrote in message That didn't work for me. I added the declares and the call in the Form_Load news:%23PQIFKrkJHA.5732@TK2MSFTNGP05.phx.gbl... > Try turning on the focus marks with a sneaky message > > Public Const WM_CHANGEUISTATE As Long = &H127 > Public Const USIF_RESET As Long = 65538 > > Public Declare Function SendMessageAny Lib "user32" Alias "SendMessageA" > (ByVal hWnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As > Any) As Long > > ' COMMENT > 'USIF_RESET = > ' (LoByte) Const UIS_CLEAR As Integer = &H2 > ' + (HiByte) Const UISF_HIDEFOCUS As Integer = &H1 > > > ' In form load event > ' For forms where the controls are added dynamically, put this line after > the form is built > > Call SendMessageAny(Me.hWnd, WM_CHANGEUISTATE, USIF_RESET, ByVal 0) > > This *should* work, I have apps with manifest & buttons with hotkeys and > they all show up, I'm moderately certain they didn't until I added this (I > could be wrong about that) > event, and no perceptable change. Perhaps there's another part missing? -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net On Thu, 19 Feb 2009 11:38:14 -0500, "Rick Raisley"
<heavymetal-A-T-bellsouth-D-O-Tnet> wrote: >I'd never noticed this before, but the underlined shortcuts placed onto Under XP (don't know about Vista), have a look at Control>command buttons (like with &Print for Print with the P underscored, >indicating a hot key) don't show up on my WinXP PC when running the EXE >using a Manifest file for the newer control looks. > >The shortcuts still work, but no one can see them. > >What's up with that?? Is there a way to make them show up? I've taken great >care to be sure I have shortcuts to my most used functions, but if they >don't show, then they're kind of worthless. Panel->Display->Appearance->Effects, there's an option to turn off shortcut keys until the ALT key is held, see if that's ticked. -- Alfie [UK] <http://www.delphia.co.uk/> There are three types of people; - Those who make things happen, - those who watch what happens - and those who wonder what happened.
Show quote
Hide quote
"Alfie [UK]" <alfie@mail.invalid> wrote in message That seems to apply only to Menus, not to the shortcuts on buttons. At news:qq3rp4dckb9vo4ln7fhf8834pkt167bfsq@4ax.com... > On Thu, 19 Feb 2009 11:38:14 -0500, "Rick Raisley" > <heavymetal-A-T-bellsouth-D-O-Tnet> wrote: > >>I'd never noticed this before, but the underlined shortcuts placed onto >>command buttons (like with &Print for Print with the P underscored, >>indicating a hot key) don't show up on my WinXP PC when running the EXE >>using a Manifest file for the newer control looks. >> >>The shortcuts still work, but no one can see them. >> >>What's up with that?? Is there a way to make them show up? I've taken >>great >>care to be sure I have shortcuts to my most used functions, but if they >>don't show, then they're kind of worthless. > > Under XP (don't know about Vista), have a look at Control > Panel->Display->Appearance->Effects, there's an option to turn off > shortcut keys until the ALT key is held, see if that's ticked. > -- least, holding down the Alt key has no effect on the buttons. -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote in message This is something that was first introduced in 1999 with Windows 2000 and news:%23luw1BrkJHA.3760@TK2MSFTNGP03.phx.gbl... > I'd never noticed this before, but the underlined shortcuts placed onto > command buttons (like with &Print for Print with the P underscored, > indicating a hot key) don't show up on my WinXP PC when running the EXE > using a Manifest file for the newer control looks. > > The shortcuts still work, but no one can see them. > > What's up with that?? Is there a way to make them show up? I've taken > great care to be sure I have shortcuts to my most used functions, but if > they don't show, then they're kind of worthless. was carried over to XP and Vista (but not Server 2003, because apparently admin types hate it). It's a user setting (and therefore should not be messed with by your program as Dave suggested) and can be found the Appearance tab on the Display applet from the Effects button (this is XP; the location is different for Win 2000 and Vista). So yeah, it's just something you've never noticed. Nor, apparently, have you noticed the many times other people have asked about it in this group. And now you know!
Show quote
Hide quote
"Jeff Johnson" <i.get@enough.spam> wrote in message Yeah, you're right, unchecking the "Hide underlined letters for keyboard news:%23ATA$OrkJHA.4448@TK2MSFTNGP05.phx.gbl... > "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote in message > news:%23luw1BrkJHA.3760@TK2MSFTNGP03.phx.gbl... > >> I'd never noticed this before, but the underlined shortcuts placed onto >> command buttons (like with &Print for Print with the P underscored, >> indicating a hot key) don't show up on my WinXP PC when running the EXE >> using a Manifest file for the newer control looks. >> >> The shortcuts still work, but no one can see them. >> >> What's up with that?? Is there a way to make them show up? I've taken >> great care to be sure I have shortcuts to my most used functions, but if >> they don't show, then they're kind of worthless. > > This is something that was first introduced in 1999 with Windows 2000 and > was carried over to XP and Vista (but not Server 2003, because apparently > admin types hate it). It's a user setting (and therefore should not be > messed with by your program as Dave suggested) and can be found the > Appearance tab on the Display applet from the Effects button (this is XP; > the location is different for Win 2000 and Vista). > navigation until I press the Alt key" shows them. What's a little silly is that WITH this checked, they still don't show up on buttons, only menus. Just silly. > So yeah, it's just something you've never noticed. Nor, apparently, have Yes, now I know. Well, I guess I filter a lot of stuff out of the group, > you noticed the many times other people have asked about it in this group. > And now you know! unless it hits that brain cell that tells me I should be interested. ;-) -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net
Show quote
Hide quote
"Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote in message That must be specific to VB6 apps with manifests. I know this because this news:%23g%23Eq3rkJHA.2516@TK2MSFTNGP05.phx.gbl... >> This is something that was first introduced in 1999 with Windows 2000 and >> was carried over to XP and Vista (but not Server 2003, because apparently >> admin types hate it). It's a user setting (and therefore should not be >> messed with by your program as Dave suggested) and can be found the >> Appearance tab on the Display applet from the Effects button (this is XP; >> the location is different for Win 2000 and Vista). >> > > Yeah, you're right, unchecking the "Hide underlined letters for keyboard > navigation until I press the Alt key" shows them. > > What's a little silly is that WITH this checked, they still don't show up > on buttons, only menus. Just silly. setting is in effect during Windows XP setup (the GUI part, of course), and the moment I tap ALT I see mnemonics on buttons. I can clearly picture them appearing on the Next and Back buttons of the setup wizard. This is a setting you can change via the control panel > Display >
Appearance > Effects > Hide underline letters for keyboard navigation... Show quoteHide quote "Jeff Johnson" <i.get@enough.spam> wrote in message news:%233fxdJskJHA.4912@TK2MSFTNGP04.phx.gbl... | "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote in message | news:%23g%23Eq3rkJHA.2516@TK2MSFTNGP05.phx.gbl... | | >> This is something that was first introduced in 1999 with Windows 2000 and | >> was carried over to XP and Vista (but not Server 2003, because apparently | >> admin types hate it). It's a user setting (and therefore should not be | >> messed with by your program as Dave suggested) and can be found the | >> Appearance tab on the Display applet from the Effects button (this is XP; | >> the location is different for Win 2000 and Vista). | >> | > | > Yeah, you're right, unchecking the "Hide underlined letters for keyboard | > navigation until I press the Alt key" shows them. | > | > What's a little silly is that WITH this checked, they still don't show up | > on buttons, only menus. Just silly. | | That must be specific to VB6 apps with manifests. I know this because this | setting is in effect during Windows XP setup (the GUI part, of course), and | the moment I tap ALT I see mnemonics on buttons. I can clearly picture them | appearing on the Next and Back buttons of the setup wizard. | | "C Kevin Provance" <BillMIsADou***@yyz.net> wrote in message Right. But the wording, with WinXP Pro, at least, is "Hide underlined news:uTnC7sskJHA.3480@TK2MSFTNGP06.phx.gbl... > This is a setting you can change via the control panel > Display > > Appearance > Effects > Hide underline letters for keyboard navigation... > letters for keyboard navigation until I press the Alt key". The problem is, with this option checked, while the MENU underlines do appear, the ones on Command Buttons, etc. do NOT appear, when pressing the Alt key. So, with this checked, you apparently NEVER get to see the underlines, which I find annoying. I go to all this trouble to set up shortcuts, making them visible with the underlines, and unless a user goes in and knows to uncheck this option, he can never see them. I was hoping Dave O's code might force the issue to show them, at least on command buttons for that app, but at least on my system, it does not. With the checkbox to Hide the underlines CHECKED, in my manifested VB app, the underlines in the menu are NOT visible until pressing the Alt key (as described above), although command buttons and such never show. Interestingly, Microsoft seems to ignore this setting at will, because Microsoft Excel and Word 2003 ALWAYS show the underlines, on both the menu items and buttons, REGARDLESS of the setting! Microsoft, again, ignoring their own rules: Business as Usual! ;-) -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net
Show quote
Hide quote
"Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote... Try this (on each form). Alternately, you might call the code from the > "C Kevin Provance" <BillMIsADou***@yyz.net> wrote in message > news:uTnC7sskJHA.3480@TK2MSFTNGP06.phx.gbl... >> This is a setting you can change via the control panel > Display > >> Appearance > Effects > Hide underline letters for keyboard navigation... >> > > Right. But the wording, with WinXP Pro, at least, is "Hide underlined > letters for keyboard navigation until I press the Alt key". > > The problem is, with this option checked, while the MENU underlines do > appear, the ones on Command Buttons, etc. do NOT appear, when pressing the > Alt key. So, with this checked, you apparently NEVER get to see the > underlines, which I find annoying. I go to all this trouble to set up > shortcuts, making them visible with the underlines, and unless a user goes > in and knows to uncheck this option, he can never see them. > > I was hoping Dave O's code might force the issue to show them, at least on > command buttons for that app, but at least on my system, it does not. KeyDown event if the Alt button is pressed, though I prefer the FormLoad. Option Explicit Private Const WM_CHANGEUISTATE As Long = &H127 Private Const UISF_HIDEFOCUS As Integer = &H1 Private Const UISF_HIDEACCEL As Integer = &H2 Private Const UIS_CLEAR As Integer = &H2 Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" ( _ ByVal hwnd As Long, _ ByVal wMsg As Long, _ ByVal wParam As Long, _ lParam As Any) As Long Private Sub Form_Load() Dim uiState As Long uiState = MakeLong(UIS_CLEAR, UISF_HIDEFOCUS Or UISF_HIDEACCEL) SendMessage Me.hwnd, WM_CHANGEUISTATE, uiState, ByVal 0 End Sub Private Function MakeLong(ByVal wLow As Integer, ByVal wHigh As Integer) As Long MakeLong = wHigh * &H10000 + wLow End Function David
Show quote
Hide quote
"David Youngblood" <d**@flash.net> wrote in message Nice, ORing UISF_HIDEACCEL into what I posted earlier is a definite news:uCAaSiukJHA.6124@TK2MSFTNGP02.phx.gbl... > "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote... >> "C Kevin Provance" <BillMIsADou***@yyz.net> wrote in message >> news:uTnC7sskJHA.3480@TK2MSFTNGP06.phx.gbl... >>> This is a setting you can change via the control panel > Display > >>> Appearance > Effects > Hide underline letters for keyboard navigation... >>> >> >> Right. But the wording, with WinXP Pro, at least, is "Hide underlined >> letters for keyboard navigation until I press the Alt key". >> >> The problem is, with this option checked, while the MENU underlines do >> appear, the ones on Command Buttons, etc. do NOT appear, when pressing >> the Alt key. So, with this checked, you apparently NEVER get to see the >> underlines, which I find annoying. I go to all this trouble to set up >> shortcuts, making them visible with the underlines, and unless a user >> goes in and knows to uncheck this option, he can never see them. >> >> I was hoping Dave O's code might force the issue to show them, at least >> on command buttons for that app, but at least on my system, it does not. > > Try this (on each form). Alternately, you might call the code from the > KeyDown event if the Alt button is pressed, though I prefer the FormLoad. > > Option Explicit > > Private Const WM_CHANGEUISTATE As Long = &H127 > Private Const UISF_HIDEFOCUS As Integer = &H1 > Private Const UISF_HIDEACCEL As Integer = &H2 > Private Const UIS_CLEAR As Integer = &H2 > > Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" ( _ > ByVal hwnd As Long, _ > ByVal wMsg As Long, _ > ByVal wParam As Long, _ > lParam As Any) As Long > > Private Sub Form_Load() > Dim uiState As Long > uiState = MakeLong(UIS_CLEAR, UISF_HIDEFOCUS Or UISF_HIDEACCEL) > SendMessage Me.hwnd, WM_CHANGEUISTATE, uiState, ByVal 0 > End Sub > > Private Function MakeLong(ByVal wLow As Integer, ByVal wHigh As Integer) > As Long > MakeLong = wHigh * &H10000 + wLow > End Function > > David improvement, I think I had to do some mucking about with spoofing keypresses to make the command button hotkeys show before. Happily in the minimal testing I've done with this little addition it seems to work straight off Thanks. Dave O.
Show quote
Hide quote
"David Youngblood" <d**@flash.net> wrote in message Yes, that worked well, David, thanks! I made the declares Public, so I news:uCAaSiukJHA.6124@TK2MSFTNGP02.phx.gbl... > "Rick Raisley" <heavymetal-A-T-bellsouth-D-O-Tnet> wrote... >> "C Kevin Provance" <BillMIsADou***@yyz.net> wrote in message >> news:uTnC7sskJHA.3480@TK2MSFTNGP06.phx.gbl... >>> This is a setting you can change via the control panel > Display > >>> Appearance > Effects > Hide underline letters for keyboard navigation... >>> >> >> Right. But the wording, with WinXP Pro, at least, is "Hide underlined >> letters for keyboard navigation until I press the Alt key". >> >> The problem is, with this option checked, while the MENU underlines do >> appear, the ones on Command Buttons, etc. do NOT appear, when pressing >> the Alt key. So, with this checked, you apparently NEVER get to see the >> underlines, which I find annoying. I go to all this trouble to set up >> shortcuts, making them visible with the underlines, and unless a user >> goes in and knows to uncheck this option, he can never see them. >> >> I was hoping Dave O's code might force the issue to show them, at least >> on command buttons for that app, but at least on my system, it does not. > > Try this (on each form). Alternately, you might call the code from the > KeyDown event if the Alt button is pressed, though I prefer the FormLoad. > didn't need all that on each form, then just called the Form_Load code in each form with shortcut letters. -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net > Yes, that worked well, David, thanks! I made the declares Public, so I Just curious, why would you need to manually call the Form_Load code since > didn't need all that on each form, then just called the Form_Load code in > each form with shortcut letters. it is automatically executed each time the form loads? "Daryl Muellenberg" <dmuellenb***@comcast.net> wrote in message I didn't mean to indicate I called Form_Load manually. I was only referring news:ewbwLVhlJHA.4372@TK2MSFTNGP02.phx.gbl... >> Yes, that worked well, David, thanks! I made the declares Public, so I >> didn't need all that on each form, then just called the Form_Load code in >> each form with shortcut letters. > > Just curious, why would you need to manually call the Form_Load code since > it is automatically executed each time the form loads? to the fact that I made the constants and declares Public, so I could include the actual code only in each Form_Load. I just mis-stated. -- Regards, Rick Raisley heavymetal-A-T-bellsouth-D-O-T-net
Form size - pixels/twips and working area
Finding the position of a certain instance of ":" in a string Low/High Values equivalent in Visual Basic VBA to VB.NET Any tips on how to make a form look more "up-to-date? Adding Checkboxes to a Listbox at Runtime Change Form's Titlebar at Runtime How to access data in treeview New Micrsoft o/s Win32_CurrentTime issue: only reading right digit of two digit .Hour |
|||||||||||||||||||||||