Jump to content

Recommended Posts

Posted

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?

Posted

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
Posted

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?

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...