Jump to content

PixelGetColor question


Recommended Posts

One of the solutions to identify item with "Баланс" text is clicking on it with right mouse button i.e open context menu on it and see items state on it. If 3rd item is disabled state or non-active state this means i am clicking on unnecessary item and it must be skipped so this means solution for me to identifying item.I am able to get handle of context menu .But after that using _GUICtrlMenu_GetItemDisabled function returns not correct results with testing several menu items index.here is code i have tested 

ConsoleWrite(_GUICtrlMenu_GetItemDisabled($hWnd,0,True)&@CRLF)
ConsoleWrite(_GUICtrlMenu_GetItemDisabled($hWnd,1,True)&@CRLF)
ConsoleWrite(_GUICtrlMenu_GetItemDisabled($hWnd,2,True)&@CRLF)
ConsoleWrite(_GUICtrlMenu_GetItemDisabled($hWnd,3,True)&@CRLF)

This code returns me all False values. But it is not correct. For the testing i have used _GUICtrlMenu_GetItemCount function and surprisingly it returned to me -1 value so it means it cannot found items . I have tested _GUICtrlMenu_GetItemText function and again result -  no success. It didnot return any text. I have checked handle of context menu that i give to these functions and it correct .I have got handle of context menu with winapi function _WinAPI_EnumProcessWindows($pPid,True) so it's getting correct handle as i see it from Window Detective software.

 So seems _GUICtrlMenu_* functions not working with Metatrader 4 soft too. I must use winapi functions to work with context menu. Now stucked in this situation.

Edited by ilqar200
Link to comment
Share on other sites

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
 Share

  • Recently Browsing   0 members

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