Using Win32 functions in Visual FoxPro Image Gallery
Printing and Print Spooler
..msdn
AddPort
AddPrinter
ClosePrinter
ConfigurePort
ConnectToPrinterDlg
DeletePort
DeviceCapabilities
DocumentProperties
EndDoc
EndPage
EnumForms
EnumJobs
EnumPorts
EnumPrinterData
EnumPrinterDrivers
EnumPrinters
EnumPrintProcessorDatatypes
EnumPrintProcessors
Escape
FindClosePrinterChangeNotification
FindFirstPrinterChangeNotification
FindNextPrinterChangeNotification
FreePrinterNotifyInfo
GetDefaultPrinter
GetPrinter
GetPrinterData
GetPrinterDriverDirectory
GetPrintProcessorDirectory
OpenPrinter
PrinterProperties
SetDefaultPrinter
SetJob
SetPrinter
StartDoc
StartPage
Code examples:
Printing text with the Escape function
Escape
..msdn    Add comment     W32 Constants      Translate this page
The Escape function enables applications to access capabilities of a particular device not directly available through GDI. Escape calls made by an application are translated and sent to the driver.
Code examples:
Printing text with the Escape function
Declaration:
int Escape(
  HDC hdc,           // handle to DC
  int nEscape,       // escape function
  int cbInput,       // size of input structure
  LPCSTR lpvInData,  // input structure
  LPVOID lpvOutData  // output structure
);
FoxPro declaration:
DECLARE INTEGER Escape IN gdi32;
    INTEGER hdc,;
    INTEGER nEscape,;
    INTEGER cbInput,;
    INTEGER lpvInData,;
    INTEGER lpvOutData
Parameters:
hdc
[in] Handle to the device context.

nEscape
[in] Specifies the escape function to be performed.

cbInput
[in] Specifies the number of bytes of data pointed to by the lpvInData parameter.

lpvInData
[in] Pointer to the input structure required for the specified escape.

lpvOutData
[out] Pointer to the structure that receives output from this escape.
Return value:
If the function succeeds, the return value is greater than zero, except with the QUERYESCSUPPORT printer escape, which checks for implementation only. If the escape is not implemented, the return value is zero.
Usage:
* some constants that used with the Escape function
#DEFINE NEWFRAME 1
#DEFINE STARTDOC 10
#DEFINE ENDDOC 11

* informs the printer that the application has finished 
* writing to a page.
= Escape(hPrnDC, NEWFRAME, 0,0,0)

* ends a print job started by the STARTDOC escape. 
= Escape(hPrnDC, ENDDOC, 0,0,0)


Translate this page:
  Spanish    Portuguese    German    French    Italian  
FreeTranslation.com offers instant, free translations of text or web pages.
Created: 2002-12-30 19:14:52
Modified: 2007-06-11 20:07:41
Visited in last 7 days: 23
User Contributed Notes:
Alex | 2006-06-20 13:00:57
Can someone tell me why escape function doesn't work in win98?
A.M. | 2006-06-20 13:18:30
What is the return value?

Copyright 2001-2014 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

Privacy policy
Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.1.68), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
Last Topics Visited (54.205.99.71)
5 sec.Function: 'RtlCompressBuffer'
27 sec.Function: 'MonitorFromWindow'
1.33 min.Function: 'StartPage'
Function group: 'Printing and Print Spooler'
3.03 min.Example: 'Winsock: reading email messages (POP3, port 110)'
3.12 min.Function: 'mixerGetDevCaps'
Function group: 'Windows Multimedia'
3.18 min.Function: 'EnumJobs'
3.22 min.Function: 'VirtualAllocEx'
Function group: 'Memory Management'
3.25 min.Function: 'LockWorkStation'
3.28 min.Function: 'WNetAddConnection'
Function group: 'Windows Networking'
3.37 min.Example: 'Winsock: connecting to a news server (NNTP, port 119)'
Google
Advertise here!