View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
DNF Karran[_6_] DNF Karran[_6_] is offline
external usenet poster
 
Posts: 1
Default Take a screenshot

A shorter version of the code on MSDN that will copy the screen to th
clip board. If you just add the declarations at the start you can the
just add the keybd_event to your code.

Duncan

Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, _
ByVal bScan As Byte, ByVal dwFlags As Long, ByVal dwExtraInfo A
Long)
Public Const VK_SNAPSHOT = &H2C


Sub PrintScreen()
keybd_event VK_SNAPSHOT, 0, 0, 0
End Su

--
Message posted from http://www.ExcelForum.com