G
Gina
All,
A co-worker is trying the following... any advise... Thanks
I am trying to take a screen print and pasting it into MS Paint however,
Paint won’t retain focus so Sendkeys sends the key strokes directly to Access
and I get a blank picture
On Error GoTo BadStart
keybd_event VK_MENU, 0, 0, 0
keybd_event VK_SNAPSHOT, 0, 0, 0
keybd_event VK_SNAPSHOT, 0, KEYEVENTF_KEYUP, 0
keybd_event VK_MENU, 0, KEYEVENTF_KEYUP, 0
Shell "mspaint.exe",1
AppActivate "untitled - Paint", True
PauseTime = 4 ' Set duration.
Start = Timer ' Set start time.
Do While Timer < Start + PauseTime
DoEvents ' Yield to other processes.
Loop
Finish = Timer ' Set end time.
TotalTime = Finish - Start
SendKeys ("^v"), True
SendKeys ("^s"), True
SendKeys "C:\Temp\Error.bmp", True
SendKeys ("{ENTER}"), True
SendKeys ("%{F4}")
Exit Function
Thank you as always.
A co-worker is trying the following... any advise... Thanks
I am trying to take a screen print and pasting it into MS Paint however,
Paint won’t retain focus so Sendkeys sends the key strokes directly to Access
and I get a blank picture
On Error GoTo BadStart
keybd_event VK_MENU, 0, 0, 0
keybd_event VK_SNAPSHOT, 0, 0, 0
keybd_event VK_SNAPSHOT, 0, KEYEVENTF_KEYUP, 0
keybd_event VK_MENU, 0, KEYEVENTF_KEYUP, 0
Shell "mspaint.exe",1
AppActivate "untitled - Paint", True
PauseTime = 4 ' Set duration.
Start = Timer ' Set start time.
Do While Timer < Start + PauseTime
DoEvents ' Yield to other processes.
Loop
Finish = Timer ' Set end time.
TotalTime = Finish - Start
SendKeys ("^v"), True
SendKeys ("^s"), True
SendKeys "C:\Temp\Error.bmp", True
SendKeys ("{ENTER}"), True
SendKeys ("%{F4}")
Exit Function
Thank you as always.