Tech or Treat! Write an article about your scariest tech disaster to win gadgets!Learn more

x
?
Solved

See this old question ... popup menus missing ....100 points

Posted on 2001-06-15
2
Medium Priority
?
142 Views
Last Modified: 2010-05-02
0
Comment
Question by:costello
[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
2 Comments
 
LVL 39

Accepted Solution

by:
appari earned 40 total points
ID: 6209349
i suppose you are loading this form from another popup menu click in the previous form. if that is the case it wont display the popup menu here. because at a time only one popup menu can be activated and if this form is a modal window it's won't display popup menu here

for example try this.

1. open a new project.
2. add two forms, form1 and form2
3. add following menus to form1.
     a    (Visible = true)
     ....a1
     b    (Visible = false)
     ....b1   (Visible = true)

4. add following code in form1

Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 2 Then PopupMenu b
End Sub

Private Sub a1_Click()
Form2.Show 1
End Sub

Private Sub b1_Click()
Form2.Show 1
End Sub

5. add following menus to form2.
     a    (Visible = false)
     ....a1

6. add following code to Form2

Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 2 Then PopupMenu a
End Sub    

7. now run the project. u can observe if you load the form from a1 click u can access popup menu in form2, but if u load form2 from b1 click it wont show form2's popup.

8.  now if u change the following code in form1 from

Private Sub b1_Click()
Form2.Show 1
End Sub

to

Private Sub b1_Click()
Form2.Show
End Sub

and run now u can see popup menu in both the cases whether u are clicking a1 or b1.

i suppose this helps you,

thank you,
Rao

0
 

Author Comment

by:costello
ID: 6267003
Hi Rao,

I see you have put a comment in both this question and the real question, but only after another comment was accepted.

Sorry for that, but for your effort, I'll award you 10 points here and an A.

costello
Community Support Moderator @ Experts-Exchange
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

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

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
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…
Suggested Courses

647 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