Docmd.findrecord acSearchAll, doesn't.

DataMiner

Registered User.
Local time
Today, 23:20
Joined
Jul 26, 2001
Messages
336
I am trying to use
docmd.findrecord on a form, with the search direction option set to acSearchAll. But this option does not seem to work.

Here's what I'm doing:

Noun.Enabled = True
Noun.SetFocus

DoCmd.FindRecord NounLookup, acEntire, False, acSearchAll, False, acCurrent, False

Noun.SetFocus
If CStr(Noun.Value) <> NounLookup Then

MsgBox "No Noun " & NounLookup & " found."

End If

ctlRunQty.SetFocus
Noun.Enabled = False

NounLookup is, of course a user-entered value on my form. I enter a value and then click a button to run this code. It works fine; if I click the button repeatedly, it keeps finding then next matching record. Where it DOESN"T work is if I start the search below the last matching record. I expected that setting acSearchAll would look both "up" and "down" to find a match... but it doesn't. :confused: Any ideas? My best guess is to just search first with acDown, and if no match is found, search again with acUp. But why doesnt acSearchAll work? What's it supposed to do, if not search both up and down????
 

Users who are viewing this thread

Back
Top Bottom