|
-
Jan 18th, 2008, 06:40 AM
#1
Thread Starter
Lively Member
Problem PopUpMenu
¡Hello!
Attach compressed file of the project: PopUpMenu.zip
Explanation of the problem:
When I click the button on the first form show the menu and opens the second form, but when I click with the right mouse button on top of the form does not show the following menu
Is there any solution?
Greetings
-
Jan 18th, 2008, 08:37 AM
#2
Re: Problem PopUpMenu
The problem you have there is the fact that you are opening the second form as modal. VB can only handle one popupmenu at a time so by opening the second form you are suspending the execution of the first popupmenu until you have finished with second form, you can either open the second form without modal or there is a work around by using a timer to give the first popupmenu time to close.
Code:
'your menu
Private Sub b_Click()
Timer1.Interval = 50
Timer1.Enabled = True
End Sub
'the timer
Private Sub Timer1_Timer()
Timer1.Enabled = False
Form2.Show vbModal
End Sub
Casey.
-
Jan 18th, 2008, 02:53 PM
#3
Re: Problem PopUpMenu
I would also suggest you use Option Explicit Korku. If you don't know what it does or how to set it up then just ask. Or do a search for this, its been talked about many times.
Keith
I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.
-
Jan 18th, 2008, 03:57 PM
#4
Thread Starter
Lively Member
Re: Problem PopUpMenu
Using Option Explicit still failing.
Resolving vbasicgirl, for the moment, it works. Thanks!!
Greetings
-
Jan 18th, 2008, 07:50 PM
#5
Re: Problem PopUpMenu
 Originally Posted by Korku
Using Option Explicit still failing.
Still failing the you've never use Option Explicit before then?
Learn to use it and get used to it.
Keith
I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.
-
Jan 20th, 2008, 03:30 PM
#6
Thread Starter
Lively Member
Re: Problem PopUpMenu
 Originally Posted by Keithuk
Still failing the you've never use Option Explicit before then?
Learn to use it and get used to it. 
Always use this option but you know persists the problem
-
Jan 20th, 2008, 03:39 PM
#7
Re: Problem PopUpMenu
 Originally Posted by Korku
Always use this option but you know persists the problem 
Well you don't in your PopUpMenu.zip.
Keith
I've been programming with VB for 25 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|