Function

PMPrintSettingsGetValue

Obtains the value of a setting in a print settings object.

Declaration

OSStatus PMPrintSettingsGetValue(PMPrintSettings printSettings, CFStringRef key, CFTypeRef  _Nullable *value);

Parameters

printSettings

The print settings object you want to access.

key

A string constant that specifies the key for the desired setting. Some keys are currently defined in PMTicket.h; other keys are user-defined.

value

A pointer to your Core Foundation variable. On return, the variable refers to a Core Foundation object that corresponds to the specified key. If no corresponding object exists, the variable is set to NULL.

Return Value

A result code. See Result Codes.

Discussion

This function, together with the function PMPrintSettingsSetValue, makes it possible to access print settings directly.

See Also

Accessing Data in Print Settings Objects

PMGetPrintSettingsExtendedData

Obtains extended print settings data previously stored by your application.

PMSetPrintSettingsExtendedData

Stores your application-specific data in a print settings object.

PMGetFirstPage

Obtains the number of the first page to be printed.

PMSetFirstPage

Sets the default page number of the first page to be printed.

PMGetLastPage

Obtains the number of the last page to be printed.

PMSetLastPage

Sets the page number of the last page to be printed.

PMGetPageRange

Obtains the valid range of pages that can be printed.

PMSetPageRange

Sets the valid range of pages that can be printed.

PMPrintSettingsGetJobName

Obtains the name of a print job.

PMPrintSettingsSetJobName

Specifies the name of a print job.

PMGetCopies

Obtains the number of copies that the user requests to be printed.

PMSetCopies

Sets the initial value for the number of copies to be printed.

PMGetCollate

Obtains a Boolean value that indicates whether the job collate option is selected.

PMSetCollate

Specifies whether the job collate option is selected.

PMGetDuplex

Obtains the selected duplex mode.

PMSetDuplex

Sets the duplex mode.

PMPrintSettingsSetValue

Stores the value of a setting in a print settings object.

PMPrintSettingsCopyAsDictionary

Creates a dictionary that contains the settings in a print settings object.

PMPrintSettingsCopyKeys

Obtains the keys for items in a print settings object.

PMGetJobNameCFString

Obtains the name of the print job.

PMSetJobNameCFString

Specifies the name of a print job.