{"name":"menuSetAction","operator":null,"title":"menuSetAction","type":"command","url":"https://community.bistudio.com/wiki/menuSetAction","revid":378340,"updated":"2026-04-02T16:31:17Z","groups":["GUI Control - Menu"],"status":"ok","replaced_by":[],"games":[{"game":"arma3","name":"Arma 3","version":"1.56"}],"since":{"game":"arma3","name":"Arma 3","version":"1.56"},"arma3_since":"1.56","branch":null,"locality":{"argument":null,"effect":null,"server_exec":false},"exec":null,"description":"Sets new action into menu entry on given path.","syntaxes":[{"syntax":"menuSetAction [idc, path, action]","since":null,"effect":null,"exec":null,"params":[{"name":"idc","type":"Number","optional":false,"default":null,"description":null,"types":["Number"],"since":null,"text":"idc: Number"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"action","type":"String","optional":false,"default":null,"description":"expression that should be executed when entry is clicked","types":["String"],"since":null,"text":"action: String - expression that should be executed when entry is clicked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"unary","operator":null,"left":null,"right":{"text":"[idc, path, action]","types":["Array"]}},{"syntax":"control menuSetAction [path, action]","since":null,"effect":null,"exec":null,"params":[{"name":"control","type":"Control","optional":false,"default":null,"description":null,"types":["Control"],"since":null,"text":"control: Control"},{"name":"path","type":"Tree View Path","optional":false,"default":null,"description":null,"types":["Tree View Path"],"since":null,"text":"path: Tree View Path"},{"name":"action","type":"String","optional":false,"default":null,"description":"expression that should be executed when entry is clicked","types":["String"],"since":null,"text":"action: String - expression that should be executed when entry is clicked"}],"returns":{"type":"Nothing","types":["Nothing"],"description":null,"text":"Nothing"},"form":"binary","operator":null,"left":{"text":"control","types":["Control"]},"right":{"text":"[path, action]","types":["Array"]}}],"examples":[{"text":"```sqf\nfindDisplay 313 displayCtrl 120 menuSetAction [[0, 1], \"systemChat 'Hello World!'\"];\n```","code":["findDisplay 313 displayCtrl 120 menuSetAction [[0, 1], \"systemChat 'Hello World!'\"];"]}],"multiplayer":null,"problems":null,"aliases":[],"see_also":["menuAction"],"notes":[],"categories":["Arma 3: New Scripting Commands","Arma 3: Scripting Commands","Command Group: GUI Control - Menu","Introduced with Arma 3 version 1.56","Scripting Commands"]}