BCW0928 Posted October 6, 2009 Share Posted October 6, 2009 Hey Guys, I'm trying to do the following: I have a ListView Control is pre-created. It has Item1,2,3,4,5,6,7. I would like to right click on one of the item in the list, let's say 3, and bring up the Context Manue. then I would like to verify if the items in the context manu are enable or disabled. Anyone has any ideal? Link to comment Share on other sites More sharing options...
furrycow Posted October 6, 2009 Share Posted October 6, 2009 Hey Guys, I'm trying to do the following:I have a ListView Control is pre-created. It has Item1,2,3,4,5,6,7. I would like to right click on one of the item in the list, let's say 3, and bring up the Context Manue. then I would like to verify if the items in the context manu are enable or disabled.Anyone has any ideal?Don't know if theres an easier way, but using _GUICtrlListView_GetHotItem($hWnd) would work..If you look in the helpfile for that function, and look at the example that is given, there is an option under there to determine whether an item has been right-clicked.Good luck. Instant Lockerz Invite - www.instantlockerzinvite.co.uk Link to comment Share on other sites More sharing options...
BCW0928 Posted October 6, 2009 Author Share Posted October 6, 2009 Don't know if theres an easier way, but using _GUICtrlListView_GetHotItem($hWnd) would work..If you look in the helpfile for that function, and look at the example that is given, there is an option under there to determine whether an item has been right-clicked.Good luck.Thanks, I was realize that there are functions for _GUICtrlListView. I think we can use the following sequence to right click the item. first use ControlListView() or _GUICtrlList_View_FindItem() functions to find the "Index" of the item in the list. Then use _GUICtrlListView_ClickItem() function to right click the "Index" item in the List.However, my second part of the question is that when we right click the item in the list, a context manu appear. I would like to know if the items in the context menu are enabled or disabled. Anyone has any idea for it? 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