Re: Is there any way I can print out the form as it looks on the screen?
- From: "Dan Tallent" <dtallent@xxxxxxxxxxxxxxxx>
- Date: Wed, 1 Jun 2005 16:43:54 -0400
This routine will print the clipboard from Word
ox=CREATEOBJECT("word.application")
ox.Visible = .t.
odoc=ox.Documents.Add()
ox.Selection.Paste
odoc.printout
This function will send the keystrokes to Windows to capture your screenshot
to the clipboard. There are probably other methods.
* Declare the Function
DECLARE INTEGER keybd_event IN Win32API ;
INTEGER, INTEGER, INTEGER, INTEGER
VK_SNAPSHOT = 44 && from the winuser.h
VK_LMENU = 164
KEYEVENTF_KEYUP = 2
KEYEVENTF_EXTENDEDKEY = 1
* To get just the Active window
DOEVENTS
keybd_event(VK_SNAPSHOT, 1, 0, 0 )
keybd_event(VK_SNAPSHOT, 1, KEYEVENTF_KEYUP, 0 )
DOEVENTS
* To get the Full windows desktop
DOEVENTS
keybd_event( VK_LMENU, 0, KEYEVENTF_EXTENDEDKEY, 0 ) && key down
keybd_event( VK_SNAPSHOT, 0, KEYEVENTF_EXTENDEDKEY, 0 )
keybd_event( VK_SNAPSHOT, 0, KEYEVENTF_EXTENDEDKEY + KEYEVENTF_KEYUP, 0 )
keybd_event( VK_LMENU, 0, KEYEVENTF_EXTENDEDKEY + KEYEVENTF_KEYUP, 0 )
DOEVENTS
I hope this helps,
Dan
"Thorkell" <thorkell@xxxxxxxxx> wrote in message
news:e00XHU9YFHA.3220@xxxxxxxxxxxxxxxxxxxxxxx
> Is there any way I can print out the form as it looks on the screen? VFP9
>
>
>
> Thanks,
>
> Thorkell
>
>
.
- Prev by Date: Re: Fox is dead, long live the fox!
- Next by Date: Re: VFP7 won't run
- Previous by thread: Fox is dead, long live the fox!
- Next by thread: Re: Is there any way I can print out the form as it looks on the screen?
- Index(es):
Relevant Pages
|