Ontosy Posted January 5, 2012 Share Posted January 5, 2012 i have: For $n = 1 To 4 $ahExtList[$n-1] = TrayCreateItem("&" & ($n + 1), $hMenuExt, $n + 1, 1) Next and then: $msg=TrayGetMsg() Switch $msg Case $ahExtList[0] .... Case $ahExtList[1] .... Case $ahExtList[2] .... Case $ahExtList[3] .... do it is possibile to use only Case $ahExtList msgbox(0,0, $ahExtList number) ? excuse my english. Link to comment Share on other sites More sharing options...
Moderators big_daddy Posted January 6, 2012 Moderators Share Posted January 6, 2012 Take a look at the example for TrayGetMsg in the AutoIt Help File. What you are asking for here is shown in that example. Link to comment Share on other sites More sharing options...
Ontosy Posted January 6, 2012 Author Share Posted January 6, 2012 What you are asking for here is shown in that example.I do not seem right Link to comment Share on other sites More sharing options...
Moderators big_daddy Posted January 6, 2012 Moderators Share Posted January 6, 2012 I read your question again. I hadn't finished my coffee yet! One option would be to catch $msg > 0. This will give you the control id and that is what is stored in each element of your array. Another option would be to use OnEvent code. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now