Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Show system menu of a hwnd
#1
i try to show the system menu of a hwnd.
after searching in google and google groups i found this
Delphi tip#155: show system menu.

int SysMenu always returns values>0.
does using point even make sense ?

Code:
Copy      Help
int hwnd=win("" "SciCalc" "Calc")
POINT p;
GetCursorPos(&p);
int SysMenu=GetSystemMenu(hwnd 0)
int intSelected = TrackPopupMenuEx(SysMenu TPM_LEFTBUTTON|TPM_RIGHTBUTTON|TPM_RETURNCMD p.x p.y hwnd 0)
SendMessage(hwnd WM_SYSCOMMAND intSelected 0)


thanks.


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)