Link to home
Start Free TrialLog in
Avatar of RudolfFraDK
RudolfFraDKFlag for Denmark

asked on

DoCmd.DoMenuItem A_FORMBAR...

I have converted a DB from access 97 to access 2002 - and now a search form dosnt work. The line of code looks like this:
DoCmd.DoMenuItem A_FORMBAR, A_EDITMENU, 10, , A_MENU_VER20
It opens a search and replace dialog, but is only supposed to open a search dialog.
How do I make it work ?
Avatar of RudolfFraDK
RudolfFraDK
Flag of Denmark image

ASKER

Oups - The search dialog is allright, but it doesnt work. Where do I edit it ?
What does the line:
DoCmd.DoMenuItem A_FORMBAR, A_EDITMENU, 10, , A_MENU_VER20
mean ?
How is this line connected to a table ?
How is this line connected to a table ?
First of all the command is setup for using ACCESS 2.0

DoCmd.DoMenuItem A_FORMBAR, A_EDITMENU, 10, , A_MENU_VER20

I don't use ACCESS 2000 yet but the A_MENU_VER20 should be changed to reflect the reference to the version of access that you are using.  The parameter list of actions is also different from one version to the next. Place your cursor behind the DoMenuItem and press your F1 key to go to help for this command.  This will assist you in updating the correct version identifier.  

As far as what this command does:  It executes from the Form Menu Bar the Edit DropDown Menu item 10 which back in ACCESS 2.0 was the Search command.  The help screen will assist you in identifying the correct parameter that you want to use.  You do not need to use a number as originally coded but you can select a parameter such as acSearch.

I hope I helped you a little.

Bob Scriver
I have tried to place my cursor behind the DoMenuItem and press the F1 key, but I dont understand the options that appear.
The search should end up in a list of hits, but when I press the search button I get an errormessage. - Maybe the problem isnt really migration related - The database is made in an english version of Access 97 but I try to open it in a Danish version og Access 2002 !?
Im deleting this question - I have solved the problem by installing access 97 besides access 2002


No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in Community Support that this question is:
 - PAQ'd and pts refunded
Please leave any comments here within the
next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

Nic;o)
ASKER CERTIFIED SOLUTION
Avatar of Jgould
Jgould

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial