473,785 Members | 2,327 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Toolbar Button as DropDown context menu

Hi,

I have a toolbar with several buttons on it, one of which is set up to
be as a DropDown button. I also have a context menu with menu items
assigend to it so when I click that button, my context menu shows up.

I have 2 questions:

1) how do I find out which menu item was clicked so I can use my
Select Case statement to perform appropriate actions depending on menu
item clicked.

2) because a toolbar button that is a DropDown menu button looks kinda
like two buttons, one with title on it and one with the arrow down
(for drop down menu items) how to set a defalult menu item? (menu item
clicked when I click the button itself without clicking on arrow down
and then selecting a menu item)

Thanks,
Dino
Nov 20 '05 #1
1 4001

I got this one :)
just add context menu and create handlers for each menu item like for
normal context menu
On Wed, 28 Jul 2004 20:15:47 GMT, Dino Buljubasic
<di**@noplaceli kehome.com> wrote:
Hi,

I have a toolbar with several buttons on it, one of which is set up to
be as a DropDown button. I also have a context menu with menu items
assigend to it so when I click that button, my context menu shows up.

I have 2 questions:

1) how do I find out which menu item was clicked so I can use my
Select Case statement to perform appropriate actions depending on menu
item clicked.

2) because a toolbar button that is a DropDown menu button looks kinda
like two buttons, one with title on it and one with the arrow down
(for drop down menu items) how to set a defalult menu item? (menu item
clicked when I click the button itself without clicking on arrow down
and then selecting a menu item)

Thanks,
Dino


Nov 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
2751
by: blabore | last post by:
I have a MDI windows forms application that uses a toolbar on the parent form. I've also setup a context menu on this form to be used as the dropdown menu for one of the toolbar buttons. However, the shortcut keys for the context menu do not seem to work for the menus, only clicking on them. Is it possible to use shortcuts this way, or will shortcuts only work with a MainMenu? Thanks in advance, Ben
2
1959
by: Curtis | last post by:
I have a toolbar and, at run time, putting on a dropdown control and adding items. All is ok, but I don't know how to catch the click event. The items are there on the drop down. They are created dynamically so I don't know what they are at design time. How do I know when one of them have been selected/clicked?
1
3559
by: Curtis | last post by:
Somehow I'm just missing something. I don't know how to catch when a user clicks on an item in a dropdown list for a dropdown style button on a toolbar. I create a new app. Form1. Add a toolbar. Add a button and make it's style dropdown. In the code I create a contextmenu and add three items. This is all fine. But when I click on one of the menu items I can't figure out how to know it's been clicked and what menu item it is.
4
4640
by: Fredrik Melin | last post by:
Have anyone seen a component or know how to create a button like toolbar dropdown button without the toolbar (to be used like a normal button) Regards Fredrik Melin
6
3132
by: Juan Pedro Gonzalez | last post by:
I wanted to add a Combobox to a toolbar... Kind of the look you get on VisualStudio's toolbar. I've been able to find some VB 6 samples, but the placeholder option is no longer available for ToolbarButtons... Does anyone know how this could be done? Looking forward to hear from you,
3
1262
by: Meghezel | last post by:
I want to Make DropDownMenu for toolbar(just like Back or forward buttons of browser) takes its menuitems from Contextmenu filled with array of menuItems I could not handle the event of clicking the menuItems because it is not available to declare array withevents can any one help to find alternative solution
1
4309
by: Joseph Geretz | last post by:
I'm writing an Addin for Outlook using C#. I am able to create the interface to my Addin by adding Menus and Buttons to the Outlook Menu and Toolbar, respectively. I'd like to add one particular button to the Toolbar, but I'd like it to function like a menu. Basically, like the native 'New' button which has a small down arrow and drops down to show a list of items (e.g. Mail Message, Contact, etc.) which can be created. If you've got...
6
8779
by: Joseph Geretz | last post by:
I'm porting a C# Outlook Addin originally engineered as a COM Addin over to use VSTO. I've gotten this to the point where my VSTO Addin installs its Menu items and Toolbar buttons when Outlook launches. I've wired up my event handler to each Menu item and toolbar button. (I use the same Event handler and I use the Tag property which is different for every Menu Item and Toolbar buton to determine which menu or button is being clicked and to...
0
2225
by: Sky | last post by:
I have an Access 2003 front-end database with custom toolbars. The toolbars work fine. One annoying feature is that at the far right edge of each custom toolbar there a small dropdown arrow. When you hover over it with the mouse, a ControlTip Text of "Toolbar Options" is displayed. If you then click on the dropdrown arrow, it displays a popup menu of "Add or Remove Buttons", with a fly-out menu with the toolbar name at the top and...
0
9647
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10357
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10163
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9959
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8988
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6744
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5397
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5532
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2894
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.