PaulChilds
Technical User
- May 21, 2002
- 195
Hi,
I have a search button which finds records in a form using a field called Identifier using a FindRecord Macro. I enter the number I want to search for in a text box called Find.
WHat I want to know is:
How do I stop the macro bringing up an error if the search doesn't find any records?
At the minute my macro is set up like so:
Action: GoToControl
Control Name: [Identifier]
Action: FindRecord
Find What: =[Find]
Match: Any part of field
Match Case: No
Search: All
Search As Formatted: No
Only Current Field: Yes
Find First: Yes
Action: GoToControl
Control Name: [Identifier]
Any ideas what to do? I'd really like for a msgbox to pop up and say 'No records found - Please try again.'
Cheers
PC
I have a search button which finds records in a form using a field called Identifier using a FindRecord Macro. I enter the number I want to search for in a text box called Find.
WHat I want to know is:
How do I stop the macro bringing up an error if the search doesn't find any records?
At the minute my macro is set up like so:
Action: GoToControl
Control Name: [Identifier]
Action: FindRecord
Find What: =[Find]
Match: Any part of field
Match Case: No
Search: All
Search As Formatted: No
Only Current Field: Yes
Find First: Yes
Action: GoToControl
Control Name: [Identifier]
Any ideas what to do? I'd really like for a msgbox to pop up and say 'No records found - Please try again.'
Cheers
PC