Solved

How disable or remove a menu option at run time?

Posted on 2001-08-07
4
146 Views
Last Modified: 2010-05-02
Basics:  VB6 sp5 on Windows NT.

Question:  Based on certain conditions I want to disable or even eliminate some menu options.  How can that be done?

Thanks.
0
Comment
Question by:EYoung
  • 2
4 Comments
 
LVL 6

Accepted Solution

by:
JonFish85 earned 25 total points
Comment Utility
MyMenuName.Enabled = False

or

MyMenuName.Visible = False

use it just like you would for a regular button...
0
 
LVL 3

Expert Comment

by:andysalih
Comment Utility
also to add to johns comment,

if you want to disable buttons or labels or text on your menu.

then

command1.enable=false

or what ever the button is called

cheers
Andy
0
 
LVL 7

Author Comment

by:EYoung
Comment Utility
Yes, that is what I have been looking for.  Thanks to both of you.

I have another question that I am not getting far on.  Could you two look at it?  Thanks.  It is:

http://www.experts-exchange.com/jsp/qManageQuestion.jsp?qid=20164266

Regards,
EYoung
0
 
LVL 6

Expert Comment

by:JonFish85
Comment Utility
glad I could help!
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

762 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

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now