VS 2010 - How To Add Options To Item Right Click Menu

Aug 31, 2010

If you right click a item.. it brings up the menu of things to do with it. How do I add something to that?

View 3 Replies


ADVERTISEMENT

Right Click Menu Options

Mar 31, 2011

The user right clicks on my picturebox object. Good.When that happens, some code of mine executes and will generate a list of options.Then a menu appears where the mouse right-clicked, made up of these options.When the user clicks on one of these options, the menu is deleted and some code is run given the option index as parameter.How can I tell when the user right clicks? I can see an event handler for "click", but that includes left clicks.How do I create one of these menus? I mean, go ahead and right click something. That's the kind of menu I'm looking for.

View 2 Replies

Make A Right Click Menu And Have It Access Options Like Copy, Paste?

Mar 14, 2009

I'm using the code from the following site to create a file manager within my app: [url]Which, I think is great. When I first started programming, I wanted to use this code, but I couldn't understand it. I love how now, I understand most of it and know how to implement it. Which, I owe much of my progress to some of you at this site Well, back to what I was saying. I want to be able to make a right click menu and have it access options like copy, paste, etc. I'm sure I can figure that out, but I can't seem to figure out how to make a right click menu.I thought I could manipulate a menustrip, but I wasn't sure how.

View 3 Replies

Insert A New Right Click Context Menu Item To The Existing Right Click Context Menu For The Active Window?

May 15, 2010

VB express 2008 .net 3.5 or .net 4.0 VB express 2010?I have written application to convert RTF to HTML. The main Purpose of the application is to copy VS code to the clipboard and covert it then put it back into the clipboard as a HTML Document so that it can be pasted into a HTML document such as Windows Live Mail. I found that code copied and pasted is spaced out in in the wrong positions.

The applications works perfect with no bugs so far. I then asked Myself how to go about doing the copy with the least amount of operator interaction. So I added an Icon to the Icon Tray with a right click menu to use to convert once the Rich Text Format was copied to the clipboard. This works fine except you have Five steps, Select the text, Copy to clipboard, Right Click the icon, Select the Converter and Paste. The normal is three steps.

To this the best solution is to add a context menu item to the active form such as the RTF editor or window. So that when you select the Rich Text to copy and right click on the form to bring up that menu then to Just Select the menu Item such as "Copy RT and Convert" I searched and found about 544000 Items and tried to restrict down to no avail. I read until I finally gave up. I did not find any code examples of this. Almost every thing I found related to the web or some other explicit document like Excel and not to the Various windows that could be active with RT in it.

how do you add a context menu item to the context menu of an active rich text format window such as WordPad or VB?I have test in my application that tests to see if it is a RTF in the clipboard so if it is not the converter does nothing.

Imports System.Threading
Imports System.IO
Imports System

[code]....

View 8 Replies

Show Context Menu On Drop Down Menu Item Right Click?

Jun 22, 2009

i want to show context menu on drop down menu item right click...As an example,Suppose we add bookmark in mozilla & when we right click on that item..context menu is showing

Code:
Private Sub MenuAddToFavorites_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles MenuAddToFavorites.MouseDown
If e.Button = Windows.Forms.MouseButtons.Right Then

[Code]......

View 5 Replies

Set Folder Options Single Or Double Click To Open Item?

Nov 4, 2010

I would like to be able to set the following settings in the folder options:

- single click to open an item
- double click to open an item

I am using Visual basic 2008 Express edition.

View 2 Replies

Add Shell Item To Right Click Windows Menu?

Mar 25, 2010

I want to run my application on Windows Desktop when click my Shell Item in right Menu, for example any antivirus application add a menu for Scan item on the right menu of Windows and you can click right button on a file and scan the file via Antivirus Application how can i do this ?

i think i have to add a value on the Registry(HKEY_CLASSES_ROOTDirectoryShell)

View 3 Replies

Add A Menu Item To The Default Right-click On Devexpress Treelist?

Dec 3, 2010

I have a DevExpress (version 9.2) TreeList that by default displays a menu containing sort ascending/descending, column chooser, and best fit when you right-click on the header of the tree.

How would I add more choices to this default menu?

View 2 Replies

Single Click On Notifyicon Menu Item Produces Two Events?

Dec 17, 2009

I have a program which puts an icon in the notification area and has a menu associated with it available by right clicking on the icon. I want the menu items to be selected by single left clicks but I also want the user to be able to single left click on the icon itself to do some other functionality.

Here's the problem - the single click on the menu first fires the notifyicon1_click() routine and then the menuitem1_click() routine. How do I know in the notifyicon1_click() whether it has been called from a menu click or a click on the icon itself?

the following piece of test code duplicates the problem

Imports System
Imports System.Drawing
Imports System.Windows.Forms

[Code]....

View 8 Replies

VS 2005 : Windows Explorer Right Click Menu Item For Application?

Apr 7, 2010

i want to put a menu item for my application to the right click menu of windows explorer.I do not want to do it programmatically but i want to do it with the .NET installer.Until now i have found that i have to insert into the registry the following keys:

HKEY_CLASSES_ROOT/*/shell/MyApplication/command
and i have to put there a new value of
"[TARGETDIR]MyApplication.exe" "-file=%1"

The problem is that i want to be able to select multiple files and then call my application with parameter all of these files.Now when i right click with many selected files my application is run for each file sepparately.I want to run my application only once and with an input parameter of all the files that are selected.Also until now i cannot add a value to the (Default) key. It only adds a new value to the registry...Also i want to be able to do the same thing with folders...

View 9 Replies

[2008] Treeview Right-click Menu Must Select Item Moused Over

Feb 3, 2009

I've got a right-click menu that comes up in a treeview - with an option to ADD to that parent node or delete a child node.

Currently I'm using the SELECTEDNODE - but what I really want to do is change the "selected node" when the right-click occurs. But I'm having a hard time seeing how to do that...

How do you use this event properly??

Private Sub CapabilitiesTreeView_MouseClick(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles CapabilitiesTreeView.MouseClick
Me.CapabilitiesTreeView.SelectedNode =
End Sub

View 1 Replies

Hypothetical Controls - Options Checked As Enabled In FrmConfig Effects - Controls (like Buttons/menu Options) Are Enabled In FrmMain

Nov 26, 2010

As i'm learning more and more about developing ive just got my head around creating classes and modules, i started wondering about something to do with configuration of applications where deployment is in a more diverse environment say in a company where different branches dont need access to all parts of a program, so i thought id throw the question out there in a basic sense and get some feedback. so i can go off and do some more reading and learning.

So the scenario in my head is like this.

So we have for arguments sake FrmConfig which is the master configuration form, then we have FrmMain which is the root menu our application general user interfaces with. So here based on what options are checked as enabled in FrmConfig effects what controls (like buttons/menu options) are enabled in FrmMain.

View 2 Replies

VB 2010 - Menu Item Which Is Set To Be The MdiWindowListItem

Apr 6, 2011

I have a menu item which is set to be the MdiWindowListItem. If I open several child windows, they appear in the Windows menu on the MDI Parent as expected. If I minimize one or more of the child forms they appear along the bottom of the parent and are still in the list. So far so good. If I select one of the non-minimized child forms which is behind another, then it comes to the front, which is what I expect. However if I select from the Windows menu item one of the minimized child forms, the it's title bar is activated showing it is selected, but it doesn't restore to its previous state. How do I get the minimized child form to automatically restore (to normal or maximised) when I select it from the Windows list.

I have tried using the Activated event for the child, but it has undesirable effects (ie restores at times when you don't want it to!)

View 5 Replies

VS 2010 Options View Control - Child Options?

Aug 20, 2011

I am in need of a form that shows various options, exactly like the Options in Visual Studio. Since there are so many options I too want them categorized, with a TreeView to the left taking care of showing the right category.The usual 'easy' approach here would be to just place a TreeView control on the form, add some nodes, and give those nodes a tag or key that corresponds to a panel or UserControl with the options for that category.Since there will be a lot of options however, this is not really feasible design-wise; the form would be cluttered with possibly 50 panels, all of which I would need to select and bring to front from time to time to add controls to them that represent the options.

So I decided to create a custom control that does exactly that. The control is very similar to my Wizard usercontrol, users can add OptionsPanels at design time, which inherit Panel and simply represent one panel of options. When they do, the panel is added to a container panel, and at the same time a TreeNode is added to a TreeView. The control uses a custom ControlDesigner to handle design-time clicks in the Treeview, selecting a different node would select and bring to front the corresponding panel, allowing the user to add the controls he wants.

Due to the design time support the problem of having 50 panels is no longer present, only one panel will be visible at a time and selecting the right panel is as simple as selecting the corresponding TreeNode, just as during run-time. Anyway, I got all this working, but only for a single 'level' of categories. As you can see in the Visual Studio options, there can be multiple levels of categories. For example, the Environment node has a bunch of children, where each child represents one 'options panel'. There can even be deeper nesting, see the Text Editor node for example.Let me begin by drawing out the basics of how my control works so far.

The main control is an OptionsView control, which contains a SplitContainer with a TreeView to the left and a OptionsPanelContainer to the right. The OptionsPanelContainer is merely a Panel to which only OptionsPanel controls can be added, and which raises events when this happens, as well as when OptionsPanels are removed from it. An OptionsPanel also inherits Panel, and these are the actual panels the users will see in the control, one for each option category.For now, each OptionsPanel has exactly one corresponding TreeNode (and vice versa). In the Visual Studio options, each 'parent' category usually has a 'General' node as the first child, and the parent and this General node show the same option panel, but I am ignoring that for the moment.

The OptionsView control has a property Panels that returns the ControlCollection (Controls property) of the OptionsPanelContainer (in other words: it returns a collection of OptionsPanels that are in this container panel).

vb.net
<Editor(GetType(Designers.OptionsPanelCollectionEditor), GetType(UITypeEditor))> _ <DesignerSerializationVisibility(DesignerSerializationVisibility.Content)> _ Public ReadOnly Property Panels As Control.ControlCollection Get Return Me.PanelContainer.Controls End Get End Property

A custom CollectionEditor for this property takes care of the designer: even though the property type is ControlCollection, the CollectionEditor knows it should create instances of the OptionsPanel control instead of just Controls.When it does this, a corresponding TreeNode is also created and its Tag property is set to the OptionsPanel. Vice versa, the Node property of the OptionsPanel is set to the node. Hence the node and panel both know their corresponding object.

vb.net
Public Class OptionsPanelCollectionEditor Inherits System.ComponentModel.Design.CollectionEditor Public Sub New(type As Type) MyBase.New(type) End Sub Protected Overrides Function CreateCollectionItemType() As System.Type

[code]....

So far so good, this all works fine. I can add Panels via the designer and when I do a new TreeNode appears in the TreeView. I can select this node and the panel becomes visible (comes to the front).Now, I am a little stuck. How do I implement child option panels? And more importantly: how do I let the user add child panels?The most logical choice I think is to let each OptionsPanel have a property (ChildPanels or something) that returns the child OptionsPanels for that panel. Once the user selects an OptionsPanel then, he can look in the property grid to find its ChildPanels property and add child panels to that.

There is a problem though: what would this property return? It must return a ControlCollection of some container (this is, I think, a requirement for the designer features to work, otherwise panels are not added to the Form.Designer.vb file). But there is no container. I cannot add them to the OptionsPanel itself, that would make no sense because the parent OptionsPanel has its own set of controls (the options itself...), there cannot be another (fully docked) Panel on top of those obviously.The container of the main OptionsView then? That is not an option either, its Controls collection holds ALL OptionsPanels, not just the children of the selected panel. I cannot 'select' only the right panels either, that would require me to return a new instance of ControlCollection, it would be impossible to return the actual ControlsCollection that holds merely a small selection of its controls.

View 5 Replies

VS 2010 Custom Shutdown Menu Item?

Oct 1, 2011

I have thought that it would be pretty cool to make Boot Snooze, iReboot and similar programs accessible from the Windows Shutdown menu. It would be a pretty neat way to interface with such programs. I realize that this may be extremely advanced stuff here, but I was wondering if anyone knows how to do this. I would prefer to be able to do this in VB.Net, but I realize it may only be possible in C++, if it is at all. I have tried Googling it, but, most likely due to the advanced nature, I have not found any good results (only "Add Hibernate", "Change default action to Hibernate", etc.).

View 5 Replies

VS 2010 Select DropDown Menu Item?

Jan 1, 2012

Id like to select one of the months in this

HTML

<div class="form-element multi-field birthday" id="birthday-form-element">
<strong>Birthday</strong>
<label class="month">

[Code].....

View 13 Replies

Make Cursor Dwell "click" A Menu Item?

Apr 11, 2012

I have a submenu whose items should be selectively greyed out (Enabled=False), and I depend on the parent menu to be clicked. In VB6, from which I'm migrating, dwelling on the parent item with the cursor raised the Click() event, and the submenu items were enabled or disabled in the Click() routine.

In VS 2008 (and I assume probably in VS 2010), the submenu items are displayed as enabled and can be directly selected, bypassing the parent item, by the user even though some should be disabled. If, dispite the apparent availability of ungreyed items, the parent item is explicitly clicked, then the submenu items are correctly initialized. What change should I make to ensure Click() processing occurs before submenu display?

View 8 Replies

Add The Menu Options That Appear?

Aug 26, 2010

I want to learn how to add the menu options that appear when you click your right mouse button.So far I have a normal menu strip control, rich text box control and I have added a ContextMenuStrip control.

I have not got a clue on how to set the properties for the contextmenustrip on the richtextbox control, so when the user clicks the right mouse button the contextmenustrip appears.

View 4 Replies

Menu Options Using Threads?

Mar 29, 2010

I would like to have threads created and perform selected operations for a menu. Basically there are 3 options and for each option, a thread should go ahead and perform that operation whilst the option is available to select other options if the operation is running and not interactive. I have tried it and after correcting a lot of compiler errors its not running correctly with one thread hanging and not giving the option to select another process.

[Code]...

View 1 Replies

Using Threads In Menu Options?

Mar 29, 2010

I have an app that has a console menu with 2/3 selections. One process involves uploading a file and performing a lengthy search process on its contents, whilst another process involves SQL queries and is an interactive process with the user. I wish to use threads to allow one process to run and the menu to offer the option for the second process to run.However you cannot run the first process twice.

main...
Dim tm As Thread = New Thread(AddressOf loadFile)
Dim ts As Thread = New Thread(AddressOf reports)

[code]....

View 2 Replies

Dropdown Menu To Change Available Options

Oct 13, 2011

My latest project is to write an app that has a drop-down menu where I can choose different office locations. Once a choice is made I want a handful of different buttons which would vary between location choice. When a button is clicked it will install a printer. I've got the button and install part down but don't know where to start with the dropdown and showing different options upon choice.

View 2 Replies

Making Two Menu Options Exclusive?

Jun 9, 2011

My app has a nice menu strip, with two tool strips, one containing file options, and other contanining options options (oO)The bad part is... the options toolstip has two subitems that should be excluse. Like: I click one, other gets unclicked and become not functional.I've tried it, but with no sucess.

View 4 Replies

VS 2008 Best Way To Create An Options Menu?

Mar 31, 2010

i have various options in my app, some complex some not, these 2 save on application exit and reload on application start themes, and layouts. There selected via a comobox each.So onto the question, how does everyone create options menus? With out using a menustrip/toolstrip?

The method i was using , was to have a picture box show a panel when it was clicked on, the panel had all the various options etc on it. This idea worked great, but meant working in design mode was a pain because the panel and everything on it had to be moved round to see the items under it on the form.

So today i decided to see what other ways i can implement a menu, and i changed it so the picturebox/button now opens a dialog, and all the options etc are on that dialog, this works great except options such as the combobox 1 and combobox2 last used setting (text data binding) doesn't load when the application is started, they only load when you go into the options. Which defeats the point, if a users going into the options just to load the settings its useless them been saved.

The time to initialize the dialog (for it to appear and be click able) is 5 - 15 seconds, not alot i know but the 1st method of using a panel it initializes instantly, but then its never really closed just made hidden, so i uses more system resources.So how does every one else implement there options menu?

View 6 Replies

Add Custom Options To Standard Context Menu Or Use Standard Options In Custom Context Menu

Dec 16, 2010

I have a text box field for which I want to use a couple of custom commands accessible via a context menu. I can add my custom context menu to my text box, but then I lose the standard windows ones (i.e. Undo, copy, paste, etc).

What I really want is a context menu with both my custom options and the standard windows options. I want that to take place only within my application (i.e. not like a shell extension).

View 2 Replies

MDI Child Form List / Sub-Menu Options

Jan 19, 2012

As you can see from the screen shot I have managed to get MDI Parents / Child forms working, and managed there to be a menu option on the Parent form that displays all the Child forms opened at the time. What I was wondering, and as of yet through research haven't discovered, is there a way when the list of windows is created, if a user highlights any child in the list it opens a sub-menu from its name (eg. Rename Window, Center Window, etc).

View 4 Replies

MDI Child Form List / Sub-Menu Options?

Jun 23, 2012

MDI Child Form List / Sub-Menu Options

View 12 Replies

Make A Menu Item On A Menu Strip Link To Another Windows Form?

Jul 25, 2009

How do I make a menu item on a menu strip link to another windows form (like a menu item that links to an about page already created in the project). I know that every coder knows how to do this, but i've read most of the instructions in the world for Visual Basic coding, but can't find ANYTHING I know coding fairly well, so I can modify it, but I can't create it my self.

View 4 Replies

Work Out Conversion And Loop Back To Menu Options?

Oct 24, 2010

I have this code below that I called a Conversion Wizard Because it converts temperature, weight and currency. It works so far but I am stuck. I don't know how to apply the correct loops to it. For example, Do While and Do Until. I want it to be able to work out a conversion then loop back to the Menu-options. So that you can do as many conversions as you like and end when option 4 is selected.

Option Explicit On
Module ConversionWizard
Sub Main()
Dim userOption As Integer
Dim farenHeight As Integer
[Code] .....

View 4 Replies

Menu Items  By Making Several Of Them Submenus To Another Menu Item

Jun 1, 2010

I have a MenuStrip with many submenus. I want to rearrange some of the menu items by making several of them submenus to another menu item.[code...]

View 2 Replies

VS 2010 How To Program What Happens When Click On A Item On A Listbox

Mar 26, 2012

the data that its inserted on the listbox comes from a access db i have this code but this only works when theres only 1 line on the listbox this code works fine when i make a search in the db by the code of family(because the family code its a primary key there can only be 1 family width that familycode) so when i get the family surname i clic on it and i get a form telling me info about the family. but if i try to search for the family surname there can be several family whit that surname. when i search the family surname the listbox will show me all the family's that have the surname now what i want its when i search a surname for eg"Smith" the program will display all the familys that have that surname and i want a code that can give me the number of the family i clicked.[code]

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved