Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
VB How-To Ask your "How do I do this with VB?" questions in this forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB How-To section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 3rd, 2004, 10:47 PM
Friend of Wrox
Points: 2,376, Level: 20
Points: 2,376, Level: 20 Points: 2,376, Level: 20 Points: 2,376, Level: 20
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: , , Australia.
Posts: 596
Thanks: 1
Thanked 3 Times in 3 Posts
Default Cascading popup menu

Hi all,

I wish to have an existing menu appear on a popup menu as a child of a popup option.

I create a popup menu dynamically loading each of the option in a loop. when the user mouses over an option I wish for a child menu to appear. The child menu is a menu that is already in existance on my form.

Can anyone please help me attach an existing menu to a dynamically created menu option.

This is the code I am using to add the menu items

Code:
                    If VennLineDriverPupJob.Item(Index).ToolTipText = MutiplePickupsToolTip Then
                        'The pickup is a multiple show the choice for this time slot.
                        thisDate = VennDrivers(counter).Job(counter2).PickUpDate
                        thisTime = VennDrivers(counter).Job(counter2).PickUpTime
                        counter4 = 0

                        'Remove any pickups in the list
                        For counter3 = 1 To mnuSelectedPickup.UBound
                            Unload frmMain.mnuSelectedPickup(counter3)
                        Next

                        'Get the pickups which have the same pickup time
                        For counter3 = 0 To UBound(VennDrivers(counter).Job)
                            If VennDrivers(counter).Job(counter3).PickUpDate = thisDate And _
                                VennDrivers(counter).Job(counter3).PickUpTime = thisTime Then
                                'This is a conflicting pickup add the pickup id to the menu
                                If counter4 > 0 Then
                                    Load frmMain.mnuSelectedPickup(counter4)
                                End If
                                frmMain.mnuSelectedPickup(counter4).Caption = VennDrivers(counter).Job(counter3).PickupID

                                counter4 = counter4 + 1
                            End If
                        Next
                        PopupMenu mnuChoosePickup
                    Else
                        PopupMenu mnuAllocate
                    End If




======================================
They say, best men are moulded out of faults,
And, for the most, become much more the better
For being a little bad.
======================================
__________________
======================================
"They say, best men are molded out of faults,
And, for the most, become much more the better
For being a little bad."
--Shakespeare
======================================




Similar Threads
Thread Thread Starter Forum Replies Last Post
Cascading menu u49698 Pro Visual Basic 2005 1 February 15th, 2007 08:28 AM
Java Cascading Menu jason_ross Java GUI 0 April 2nd, 2006 11:57 PM
Popup Menu rweide Javascript 5 June 24th, 2005 03:28 PM
Popup Menu Help No. 2 tdaustin Javascript How-To 2 July 8th, 2004 07:11 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.