Click here to Skip to main content
15,910,277 members
Home / Discussions / C#
   

C#

 
GeneralRe: Control visible changed event Pin
godvicien13-Oct-10 20:53
godvicien13-Oct-10 20:53 
QuestionGrid Veiw Pin
papa198010-Mar-06 4:19
papa198010-Mar-06 4:19 
AnswerRe: Grid Veiw Pin
ToddHileHoffer10-Mar-06 8:12
ToddHileHoffer10-Mar-06 8:12 
GeneralRe: Grid Veiw Pin
papa198011-Mar-06 22:39
papa198011-Mar-06 22:39 
QuestionDynamic Menu Pin
vatzcar10-Mar-06 3:56
vatzcar10-Mar-06 3:56 
AnswerRe: Dynamic Menu Pin
eggsovereasy10-Mar-06 7:40
eggsovereasy10-Mar-06 7:40 
GeneralRe: Dynamic Menu Pin
vatzcar10-Mar-06 22:17
vatzcar10-Mar-06 22:17 
AnswerRe: Dynamic Menu Pin
Luis Alonso Ramos12-Mar-06 17:52
Luis Alonso Ramos12-Mar-06 17:52 
You could save the MenuItems in an array:
MenuItem[] menuItems = new MenuItem[arrValue.Length];

for(int i = 0; i < arrValue.Length; i++)
{
    menuItems[i] = mnuMod.MenuItems.Add(arrValue[i], new EventHandler(mnuModMenu_Click));
}
 
// Add items to the first submenu
menuItems[i].MenuItems.Add("First submenu's first item", new EventHandler(...));
Just remember that if you use the same event handler, you'll have to identify in it which menu item was selected, and if you didn't save all the MenuItem references, you'll have to do it by text.

-- LuisR



Luis Alonso Ramos
Intelectix - Chihuahua, Mexico

Not much here: My CP Blog!


The amount of sleep the average person needs is five more minutes. -- Vikram A Punathambekar, Aug. 11, 2005
Questionserializing a class containing hash table as one of its objects Pin
Anupam Mazumdar10-Mar-06 3:33
Anupam Mazumdar10-Mar-06 3:33 
AnswerRe: serializing a class containing hash table as one of its objects Pin
Judah Gabriel Himango10-Mar-06 3:53
sponsorJudah Gabriel Himango10-Mar-06 3:53 
Questiondrag and drop problem Pin
Gyozo Gaspar10-Mar-06 3:20
Gyozo Gaspar10-Mar-06 3:20 
AnswerRe: drag and drop problem Pin
Judah Gabriel Himango10-Mar-06 3:56
sponsorJudah Gabriel Himango10-Mar-06 3:56 
QuestionUpload Pin
albCode10-Mar-06 3:03
albCode10-Mar-06 3:03 
AnswerRe: Upload Pin
Judah Gabriel Himango10-Mar-06 3:58
sponsorJudah Gabriel Himango10-Mar-06 3:58 
QuestionGet connection string in web.config when register RemoteObject on IIS with .Net Remoting Pin
cuong-nm10-Mar-06 2:56
cuong-nm10-Mar-06 2:56 
QuestionProgramming with the XMLDom in C# Pin
ncotton10-Mar-06 2:06
ncotton10-Mar-06 2:06 
AnswerRe: Programming with the XMLDom in C# Pin
Christian Graus29-Jul-07 19:11
protectorChristian Graus29-Jul-07 19:11 
QuestionHow to make a setup project which install two applications Pin
psmukil10-Mar-06 0:10
psmukil10-Mar-06 0:10 
AnswerRe: How to make a setup project which install two applications Pin
spif200110-Mar-06 3:42
spif200110-Mar-06 3:42 
GeneralRe: How to make a setup project which install two applications Pin
psmukil12-Mar-06 18:05
psmukil12-Mar-06 18:05 
AnswerRe: How to make a setup project which install two applications Pin
Libor Tinka10-Mar-06 3:45
Libor Tinka10-Mar-06 3:45 
GeneralRe: How to make a setup project which install two applications Pin
psmukil12-Mar-06 18:04
psmukil12-Mar-06 18:04 
GeneralRe: How to make a setup project which install two applications Pin
psmukil12-Mar-06 18:29
psmukil12-Mar-06 18:29 
QuestionLocking files Pin
Sandrina10-Mar-06 0:04
Sandrina10-Mar-06 0:04 
QuestionMSMQ with .NET 2005 ... question Pin
Yanshof9-Mar-06 22:39
Yanshof9-Mar-06 22:39 

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.