PC Review


Reply
Thread Tools Rate Thread

Ctrl+F problem

 
 
David Mc
Guest
Posts: n/a
 
      15th Sep 2003
Currently i have a form and an event that traps Ctrl+F or
the shortcut to the find command. The problem is when ever
the F is pressed the find dalogue appears. How can i trap
the Ctrl+F together.

Thanks

My code is below:

Private Sub Form_KeyDown(KeyCode As Integer, Shift As
Integer)

If (KeyCode = 17) And (bolCtrl = False) Then
bolCtrl = True
End If

If (bolCtrl = True) And (KeyCode = 70) Then

DoCmd.GoToControl "txtSurname"
DoCmd.DoMenuItem acFormBar, acEditMenu, 9

End If

End Sub

 
Reply With Quote
 
 
 
 
Tim Ferguson
Guest
Posts: n/a
 
      15th Sep 2003
"David Mc" <(E-Mail Removed)> wrote in
news:020901c37ba3$8d6e5610$(E-Mail Removed):

> If (bolCtrl = True) And (KeyCode = 70) Then
>
> DoCmd.GoToControl "txtSurname"
> DoCmd.DoMenuItem acFormBar, acEditMenu, 9
>
> End If
>
>


I have no idea what bolCtrl means, but the normal way to do this would be

If (Shift And acCtrlMask) and (KeyCode = 70) Then



and don't forget to set KeyCode to zero when exiting the procedure, to
prevent the default seach box appearing anyway.

Hope that helps



Tim F

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ctrl-PgDn Problem after Ctrl-F (Search) Wordleast Microsoft Word Document Management 3 13th Sep 2009 07:10 PM
Can I set ctrl+s and ctrl+o window size & ctrl+o save as type defa Moonbarker Osbourne Windows XP General 1 18th Jan 2008 02:10 PM
Shortcut keys like Ctrl+C, Ctrl+V, Ctrl+A etc Not Working gettechtips@yahoo.co.in Windows XP General 1 23rd Sep 2006 12:43 PM
Re: VB script that mimics CTRL+C, CTRL+G, CTRL+V, ENTER? Fergus Cooney Microsoft VB .NET 0 8th Nov 2003 01:24 AM
Problem with Ctrl-C / Ctrl-V C. Vollmer Microsoft Dot NET Compact Framework 0 24th Sep 2003 01:16 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:54 AM.