I am developing an automation tool. I want to click listview item of another process programatically. I have partially succeeded in doing. But I am getting a slightly different output.I have used NMITEMACTIVATE(I have also used PostMessage Instead of SendMessage in the code below).
Code:NMITEMACTIVATE nmbh; nmbh.hdr.code = NM_DBLCLK; nmbh.hdr.hwndFrom=g_hWnd; nmbh.hdr.idFrom=GetDlgCtrlID(g_hWnd); nmbh.iItem=itemval; nmbh.iSubItem=0; nmbh.uNewState=0; nmbh.uOldState=0; nmbh.uChanged=0; nmbh.uKeyFlags=0; SendMessage(GetParent(g_hWnd), WM_NOTIFY,(WPARAM)g_hWnd,(LPARAM)&nmbh);




Reply With Quote
