View Full Version : Menu Item : Check In Runtime
how do i (in runtime) make a menu item "checked" ?
i searched the action wizard and didnt find anything.. maybe missed it ?
thnx,
Mina
TJ_Tigger
11-02-2005, 02:55 PM
There are a couple of ways, you can use the Application.GetMenu which will return a table with the contents of the menu. You can then modify that table and then use Application.SetMenu to reload that menu back into the application. There is also a global function g_OnUpdateMenuCheck I think is the name of the function. You can use that to modify the menu on the fly.
Tigg
appreciate ur help :yes thnx
though an example would be good
AXXESS
11-04-2005, 09:13 AM
See an example from Desmond here (http://www.indigorose.com/forums/showthread.php?t=13244).
:yes
TJ_Tigger
11-04-2005, 10:06 AM
Here is a sample using the built-in function.
Look in the global function to see two functions that control whether the menu item will be checked or not. The global function g_OnUpdateMenuCheck is called for each item in the menu looking to see if there is a true or false value and checks that item according to the returned value. This simple project will check the only item in the second menu if there is text selected.
HTH
Tigg
just what i was looking for!
thanks
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.