Solved

Using autoexec macro to remove default menu bar and database window

Posted on 1998-08-31
5
1,450 Views
Last Modified: 2008-02-07
Hi folks, I'm using A97.
In A2.0, you used to be able to say "database.hide" or something to that effect to hide the main database window. I don't find that functionality among the macro options in A97. What's the proper macro command to hide the database window as part of the autoexec (macro) process?
Also, I'd like to hide the default menu bar, so that none shows during runtime. Unfortunately, while the "built-in menu" shows up as one of the toolbars in Access' interactive mode, when I try to find it as an argument to the "ShowToolbar" macro command, it's not there. How can I execute this most simply?

Finally, I have a "developer reset" macro that lets me quickly return to my preferred settings for working on the app. If you have answers to the above, I'd also appreciate the way to reset these items to visible for that purpose.
Thanks!
0
Comment
Question by:mbunster
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 

Author Comment

by:mbunster
ID: 1960830
Edited text of question
0
 
LVL 5

Expert Comment

by:tuvi
ID: 1960831
The macro for hide database window is: RunCommand WindowHide
and to reset it is RunCommand WindowUnHide.
Usually I make an AutoKeys macro assigning WindowUnHide to a shortcut key so to unhide it during development.

For hiding the toolbar is: ShowToolbar Database No and ShowToolbar Formview No and ShowToolbar Print Preview No. These are usually sufficient, since most of your applications involving database view, form, and report.

To reset the toolbars, change it to yes. You can assign all these yes and unhide database window to a short cut key.
0
 

Author Comment

by:mbunster
ID: 1960832
Well, the first half works great--thanks.
However, the second part of the solution does not remove the default menu bar. I think you might have misread my question to ask about removing some of the various toolbars that are usually on (or might be). I'm talking about the main menu bar--the line at the top that says File--Edit--View, etc.
Sorry to reject the whole answer when there's partial credit to give...
0
 

Accepted Solution

by:
sanctified earned 70 total points
ID: 1960833
Create a macro named "beep". That's all this macro should do. once you have done this, save your "beeping" macro.

Next, go to your form, go to your form design screen. Second, Click "View" then "Properties...". Next, click the "All" tab in the pop-up menu, then scroll down to the option that says "Menu Bar" here, type in or select your macro "beep"

Now when your form is opened it will run this macro to look for a new menu bar and will see no settings, so will only beep, and remove your text.

Enjoy.
0
 

Author Comment

by:mbunster
ID: 1960834
Thanks sanctified...works like a charm.
I 'm giving a B only because I really only needed half the answer.

0

Featured Post

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question