Click here to Skip to main content
16,005,038 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralEmail application using SMTP Pin
tonymaclennan7-Aug-04 7:06
tonymaclennan7-Aug-04 7:06 
GeneralMail sending (SMTP) using winsock through proxy server Pin
ChauhanJaved7-Aug-04 1:02
ChauhanJaved7-Aug-04 1:02 
GeneralRe: Mail sending (SMTP) using winsock through proxy server Pin
Dave Kreskowiak9-Aug-04 5:37
mveDave Kreskowiak9-Aug-04 5:37 
GeneralVB.NET / FTP / PGP Pin
Member 7339436-Aug-04 14:48
Member 7339436-Aug-04 14:48 
GeneralRe: VB.NET / FTP / PGP Pin
progload8-Aug-04 17:55
progload8-Aug-04 17:55 
GeneralContext Menu's Pin
skytribe6-Aug-04 14:28
skytribe6-Aug-04 14:28 
GeneralRe: Context Menu's Pin
gthompson20057-Aug-04 14:43
gthompson20057-Aug-04 14:43 
GeneralRe: Context Menu's Pin
Anonymous8-Aug-04 1:10
Anonymous8-Aug-04 1:10 
That may work in this instance - but the concept is that I want something that is generic enough that I can re-use anywhere in app. Having to create many context menu's of different forms is not really what I want to occur.

So What I'd like is that I can Call a routine CreateContextMenu(byval MenuType as integer)

which would create a Context Menu for a specific type of Menu (Say Business Code, Order, Invoice etc.)

This adds Standard menu item such as "Open", "New" etc. which at the moment are calling functions called OpenFunctions and NewFunctions. which determine the actual real function to be called such as OpenOrder, OpenBusinessCode etc.

Determining which specific function to be called is handled by looking at a application level property which changes depending upon the listview currently selected.

Ultimately what I'm trying to do is pass a parameter into the OpenFunctions and NewFunctions procedures which are used to determine the specifc type of menu to create.

But that would involve when setting up menuItems making the AddressOf clause pointing to the function accept a paramater

So Ideally I'd like to do something like

Sub OpenFunctions(byval iType as integer)
Dim conMenu As New ContextMenu
Dim menuItem1 As New MenuItem


IF iType <> 0 then
menuItem1.Text = "&test"
conMenu.MenuItems.Add(menuItem1)
AddHandler menuItem1.Click, AddressOf OpenFunctions(iType)
else
throw new exception ("Invalid Type!!!")
end if


End Sub


But cant seem to get the following line .... to work
AddHandler menuItem1.Click, AddressOf OpenFunctions(iType)


I think this is the key - being able to pass the addressof a function with parameters.
GeneralRe: Context Menu's Pin
gthompson20058-Aug-04 5:40
gthompson20058-Aug-04 5:40 
GeneralRe: Context Menu's Pin
Anonymous9-Aug-04 2:16
Anonymous9-Aug-04 2:16 
GeneralDesigning custom GUI's using VB.net Pin
Anonymous6-Aug-04 11:33
Anonymous6-Aug-04 11:33 
Generalhelp Pin
bassemhoussam6-Aug-04 10:59
bassemhoussam6-Aug-04 10:59 
GeneralRe: help Pin
Dave Kreskowiak7-Aug-04 6:29
mveDave Kreskowiak7-Aug-04 6:29 
GeneralMSchart in VB.net Pin
megadith6-Aug-04 10:37
megadith6-Aug-04 10:37 
GeneralRe: MSchart in VB.net Pin
Dave Kreskowiak7-Aug-04 6:28
mveDave Kreskowiak7-Aug-04 6:28 
GeneralRe: MSchart in VB.net Pin
megadith10-Aug-04 8:41
megadith10-Aug-04 8:41 
GeneralSimple Grid in VB.NET Pin
Anonymous6-Aug-04 9:55
Anonymous6-Aug-04 9:55 
GeneralRe: Simple Grid in VB.NET Pin
Member 7339436-Aug-04 14:52
Member 7339436-Aug-04 14:52 
GeneralAccessing Object property of OLEFormat Pin
smritiy6-Aug-04 9:45
smritiy6-Aug-04 9:45 
GeneralRe: Accessing Object property of OLEFormat Pin
Dave Kreskowiak7-Aug-04 6:24
mveDave Kreskowiak7-Aug-04 6:24 
GeneralRe: Accessing Object property of OLEFormat Pin
smritiy9-Aug-04 8:40
smritiy9-Aug-04 8:40 
GeneralCommunicate with Digitizer Pin
SonnyBono6-Aug-04 7:22
SonnyBono6-Aug-04 7:22 
GeneralRe: Communicate with Digitizer Pin
Dave Kreskowiak6-Aug-04 8:09
mveDave Kreskowiak6-Aug-04 8:09 
GeneralWeb Service Help Pin
inetmaster6-Aug-04 5:48
inetmaster6-Aug-04 5:48 
GeneralRe: Web Service Help Pin
Dave Kreskowiak6-Aug-04 7:16
mveDave Kreskowiak6-Aug-04 7:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.