
Two Methods of
Communication with Applications
lMore robust
lSimulates actions the same way the
actual program
does
lHard to find applications API constants
lGets the job done but with issues
lNeed window active - use SetForegroundWindow
API
call
lProblems with minimized windows
1) SendMessage API call
2) Applications shortcuts
Example: SendMessage(hWinAmp, WA_PLAY)
Example: SetForegroundWindow(hWord) SendKeys(“+s”)