Sub CxMenu1_Click(ByVal sender As Object, ByVal e As EventArgs)
Sub CxMenu2_Click(ByVal sender As Object, ByVal e As EventArgs)
Sub CxMenu3_Click(ByVal sender As Object, ByVal e As EventArgs)
.
.
.
Sub CxMenu100_Click(ByVal sender As Object, ByVal e As EventArgs)
How do you create these sub or procs dynamically?
Lets say I had MenuItem1, MenuItem2,MenuItem3.... MenuItem100
Obviously I don't want to statically code 100 Sub procedures, because I may have 101 choices. Then the code will break.
So as I am looping through creating the menu choices, I want to:
(A) Dynamically create a sub as a AddHandler for each Context Menu Item.
OR
(B) Create one Handler, get the Context Menu Selected Value, and then branch with Select Case to different code snippets within the Sub.
Did I clarify myself?
Thanks for any Ideas!
Barry