CDC::StartDoc

int StartDoc( LPDOCINFO lpDocInfo );

Return Value

The value –1 if there is an error such as insufficient memory or an invalid port specification occurs; otherwise a positive value.

Parameters

lpDocInfo

Points to a DOCINFO structure containing the name of the document file and the name of the output file.

Remarks

Informs the device driver that a new print job is starting and that all subsequent StartPage and EndPage calls should be spooled under the same job until an EndDoc call occurs. This ensures that documents longer than one page will not be interspersed with other jobs.

For Windows versions 3.1 and later, this function replaces the STARTDOC printer escape. Using this function ensures that documents containing more than one page are not interspersed with other print jobs.

StartDoc should not be used inside metafiles.

CDC OverviewClass MembersHierarchy Chart

See Also   CDC::Escape, CDC::EndDoc, CDC::AbortDoc