Converting Access 2.0 to Access 97/2002 
Author Message
 Converting Access 2.0 to Access 97/2002

DoMenuItem(MenuType, MenuBar,MenuChoice,SubMenuChoice,Version)

Comes from Sams Access 2 Develpers Guide SE


Quote:
>I just inherited an old Access db that still has a
>DoMenuItem line in it.  (DoCmd.DoMenuItem 0, 0, 2) I can't
>for the life of me remember what 0, 0, 2 did.  I'm guess
>File Menu, ?, ?.  From the location in the code, it would
>seem to be trying to make Access quit, but that's not what
>it's doing.  In fact, when I step through the code, I
>don't see any effect from running that line.

>Anyone have an old reference for this?



Wed, 08 Sep 2004 02:15:07 GMT  
 Converting Access 2.0 to Access 97/2002
Have you tried specifying the Access version in the DoMenuItem arguments:

    DoCmd.DoMenuItem 0, 0, 2, , acMenuVer20

?

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(to reply via e-mail, remove NOSPAM from address)


Quote:
> I just inherited an old Access db that still has a
> DoMenuItem line in it.  (DoCmd.DoMenuItem 0, 0, 2) I can't
> for the life of me remember what 0, 0, 2 did.  I'm guess
> File Menu, ?, ?.  From the location in the code, it would
> seem to be trying to make Access quit, but that's not what
> it's doing.  In fact, when I step through the code, I
> don't see any effect from running that line.

> Anyone have an old reference for this?



Sat, 11 Sep 2004 04:19:54 GMT  
 Converting Access 2.0 to Access 97/2002
Jenny,

Wow it's been a long time for me to see that syntax. I believe that the
developer's intention was to Close the current Form. The actual translation
in English is
docmd.DoMenuItem Form, File, Close. The arguments for the DoMenuItem are
Menu Bar, Menu Name, Command and Sub Command.

You could make the modification to add the Access version, however I would
recommend using the updated syntax

Docmd.close

I hope this helps,

Darla Hogenson
Microsoft

This posting is provided "AS IS" with no warranties, and confers no rights.



Sat, 11 Sep 2004 05:27:59 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Converting VB Code from Access 97 to Access 2002 or higher

2. Procedures for Converting an Access 97 MDB to Access 2002

3. Access 97 upgrade to Access 2000 or Access 2002

4. Converting Access 2.0 to Access 97

5. Converting Access 2.0 modules to Access 97

6. Convert Access 2.0 Dbf-file to Access 97 Dbf-file

7. Convert Access 2.0 database into Access 97

8. Help: convert access 2.0 to access 97 using VB 5.0

9. Converting Access 2.0 DB to Access 97 DB in VB code

10. Tips on migration from Access 97 to Access 2002

11. Access 97 vs Access 2002 (XP)

12. Convert API from Access 2.0 to 97

 

 
Powered by phpBB® Forum Software