Set a MenuItem's ID

  • Thread starter Thread starter Saul775
  • Start date Start date
S

Saul775

In C#, is it possible to set a MenuItem's ID without calling and importing
the Win32 API function "SetMenuItemInfo?" Perhaps another class in C#
contains a method I'm looking for?

Thank you.
 
Saul,

Very unlikely. The MenuItem classes are going to wrap all of that for
you. The API function is probably the best bet.
 
Saul775 said:
In C#, is it possible to set a MenuItem's ID without calling and importing
the Win32 API function "SetMenuItemInfo?" Perhaps another class in C#
contains a method I'm looking for?

There's a MenuItem.MenuID property... it is protected, so you can either use
instances derived from MenuItem or reflect against the protected property.
 
Back
Top