PrintTicketConverter.ConvertPrintTicketToDevMode PrintTicketConverter.ConvertPrintTicketToDevMode PrintTicketConverter.ConvertPrintTicketToDevMode Method

Definition

Converts the specified PrintTicket to an unmanaged DEVMODE structure.

Overloads

ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType)

Converts the specified managed PrintTicket to an unmanaged DEVMODE structure that is based on the DEVMODE structure identified by the BaseDevModeType.

ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType, PrintTicketScope) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType, PrintTicketScope) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType, PrintTicketScope)

Converts the specified managed code PrintTicket with the specified scope, into an unmanaged DEVMODE structure that is based on the DEVMODE structure identified by the BaseDevModeType.

ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType)

Converts the specified managed PrintTicket to an unmanaged DEVMODE structure that is based on the DEVMODE structure identified by the BaseDevModeType.

public:
 cli::array <System::Byte> ^ ConvertPrintTicketToDevMode(System::Printing::PrintTicket ^ printTicket, System::Printing::Interop::BaseDevModeType baseType);
public byte[] ConvertPrintTicketToDevMode (System.Printing.PrintTicket printTicket, System.Printing.Interop.BaseDevModeType baseType);
member this.ConvertPrintTicketToDevMode : System.Printing.PrintTicket * System.Printing.Interop.BaseDevModeType -> byte[]

Parameters

printTicket
PrintTicket PrintTicket PrintTicket

The PrintTicket to convert.

baseType
BaseDevModeType BaseDevModeType BaseDevModeType

A value that identifies whether to use the user default or printer default DEVMODE as the base DEVMODE.

Returns

Byte[]

A Byte array that contains the new DEVMODE structure.

Exceptions

The value of printTicket is null (Nothing in Visual Basic).

The content of printTicket is not well-formed.

Remarks

The scope of the PrintTicket parameter must be the entire print job.

This method does not validate the PrintTicket. To validate it, use MergeAndValidatePrintTicket.

For more information on the DEVMODE structure, see DEVMODE.

ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType, PrintTicketScope) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType, PrintTicketScope) ConvertPrintTicketToDevMode(PrintTicket, BaseDevModeType, PrintTicketScope)

Converts the specified managed code PrintTicket with the specified scope, into an unmanaged DEVMODE structure that is based on the DEVMODE structure identified by the BaseDevModeType.

public:
 cli::array <System::Byte> ^ ConvertPrintTicketToDevMode(System::Printing::PrintTicket ^ printTicket, System::Printing::Interop::BaseDevModeType baseType, System::Printing::PrintTicketScope scope);
public byte[] ConvertPrintTicketToDevMode (System.Printing.PrintTicket printTicket, System.Printing.Interop.BaseDevModeType baseType, System.Printing.PrintTicketScope scope);
member this.ConvertPrintTicketToDevMode : System.Printing.PrintTicket * System.Printing.Interop.BaseDevModeType * System.Printing.PrintTicketScope -> byte[]

Parameters

printTicket
PrintTicket PrintTicket PrintTicket

The PrintTicket to convert.

baseType
BaseDevModeType BaseDevModeType BaseDevModeType

A value that identifies whether to use the user default or printer default DEVMODE as the base DEVMODE.

scope
PrintTicketScope PrintTicketScope PrintTicketScope

A PrintTicketScope value that specifies whether the conversion of the PrintTicket should be done at the scope of a page, a document, or an entire print job.

Returns

Byte[]

A Byte buffer that represents the new DEVMODE structure.

Exceptions

The value of printTicket is null (Nothing in Visual Basic).

The content of printTicket is not well-formed.

The baseType is not a valid BaseDevModeType value.

-or-

The scope is not a valid PrintTicketScope value.

Remarks

This method does not validate the PrintTicket. To validate it, use MergeAndValidatePrintTicket.

For more information on the DEVMODE structure, see DEVMODE.

Applies to