Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / February 2007

Tip: Looking for answers? Try searching our database.

Fix so FindFirst works with Caps Lock On.

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
bw - 28 Nov 2006 18:55 GMT
Below is the event for a combo box.
If I enter the name with Caps Lock OFF,  it works fine.
If I enter the name with Caps Lock ON, it doesn't work.
I'd like it to work whether Caps Lock is On or Off.

Private Sub lblBankName_AfterUpdate()
   Dim rs As Object
   Set rs = Me.Recordset.Clone
   rs.MoveFirst
   rs.FindFirst "[BankID] = " & Str(Me![lblBankName])
   If rs.NoMatch Then
       MsgBox "Record not found"
       rs.MoveFirst
       Me.lblBankName = [BankID]
   Else
       Me.Bookmark = rs.Bookmark
   End If
End Sub

--
Douglas J. Steele - 28 Nov 2006 19:50 GMT
Given that Jet (the database engine used by Access) is case-insensitive, it
doesn't make sense that case should matter.

What exactly do you mean by "enter the name"? Are you talking about
selecting an entry in the list using the mouse, typing an entry that exists
in the list, or typing an entry that doesn't exist in the list? (I'm
assuming lblBankName is the name of your combo box)

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

> Below is the event for a combo box.
> If I enter the name with Caps Lock OFF,  it works fine.
[quoted text clipped - 14 lines]
>    End If
> End Sub
bw - 28 Nov 2006 20:35 GMT
Yes, lblBankName is the name of the combo box.
I'm talking about typing an entry that exists in the list.

Assume the first name in the list, which has the focus, is "Bank One".
Also assume a bank name of "Finance Bank" in the list and "Fish Bank" is
also in the list.
I can type "fis" to go to the "Fish Bank" record.

But typing "FIS" (or even "FI") seems to cause the focus to go to the
the 3rd character of the first name in the list which matches the typed
input.  So the resulting name in the box looks like this after each
character is typed:
F>Finance Bank
FI>Finance Bank
FIS>FiSance Bank.....The focus in now after the 3rd character, not on
the whole field.

> Given that Jet (the database engine used by Access) is
> case-insensitive, it doesn't make sense that case should matter.
[quoted text clipped - 22 lines]
>>    End If
>> End Sub
Douglas J. Steele - 28 Nov 2006 22:07 GMT
I'm afaid I'm unable to reproduce your problem, so I can't offer any
suggestions.

Signature

Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no private e-mails, please)

> Yes, lblBankName is the name of the combo box.
> I'm talking about typing an entry that exists in the list.
[quoted text clipped - 39 lines]
>>>    End If
>>> End Sub
bw - 30 Nov 2006 20:34 GMT
Well, it turns out that "my" problem has nothing to do with the
procedure I had shown.  Instead, this seems like any combo box has the
same "problem".

Try this:
Make a Table1 with BankID (autonumber) and BankName (Text).
Enter three BankNames as follows:
1 Fisher Bank
2 Finance Bank
3 Financial Bank

Now make a form with  an unbound combo box with a row source
SELECT Table1.FieldID, Table1.FieldValue
FROM Table1;

Now put the caps lock on and type FINANCE BANK in the combo box.
With the caps lock on, you cannot find the Finance Bank.

I know this is a minor problem, but I'd like to know how to avoid it, if
possible.

> I'm afaid I'm unable to reproduce your problem, so I can't offer any
> suggestions.
[quoted text clipped - 43 lines]
>>>>    End If
>>>> End Sub
SteveInBeloit - 19 Feb 2007 18:35 GMT
bw,

Did you ever find a fix to this, I am battling it also.

Steve

> Well, it turns out that "my" problem has nothing to do with the
> procedure I had shown.  Instead, this seems like any combo box has the
[quoted text clipped - 64 lines]
> >>>>    End If
> >>>> End Sub
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.