PrintCustomItemDetails Класс
Определение
Важно!
Некоторые сведения относятся к предварительной версии продукта, в которую до выпуска могут быть внесены существенные изменения. Майкрософт не предоставляет никаких гарантий, явных или подразумеваемых, относительно приведенных здесь сведений.
Позволяет приложениям добавлять коллекцию перечисляемых параметров в процесс печати приложения.
public ref class PrintCustomItemDetails sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class PrintCustomItemDetails final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class PrintCustomItemDetails
Public NotInheritable Class PrintCustomItemDetails
- Наследование
- Атрибуты
Требования к Windows
Семейство устройств |
Windows 10 (появилось в 10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
|
API contract |
Windows.Foundation.UniversalApiContract (появилось в v1.0)
|
Комментарии
Ниже приведен фрагмент кода, показывающий, как получить объект :
// Create a new list option.
// This code creates a new item list option that will be shown to the user.
PrintCustomItemListOptionDetails pageFormat =
printDetailedOptions.CreateItemListOption("PageContent", "Pictures");
pageFormat.AddItem("PicturesText", "Pictures and text");
pageFormat.AddItem("PicturesOnly", "Pictures only");
pageFormat.AddItem("TextOnly", "Text only");
// Add the custom option to the option list.
printDetailedOptions.DisplayedOptions.Add("PageContent");
// Later in your app, when you want to access the list created above,
// but you don't have access to the pageFormat variable that was returned
// when the list was created, you can get it by looking up the same
// optionId that you used to create the list.
PrintCustomItemListOptionDetails printCustomItemListOptionDetails =
(PrintCustomItemListOptionDetails)printDetailedOptions.Options["PageContent"];
// printCustomItemDetails is available in the Items list from the
// PrintCustomItemsListOptionDetails object.
var printCustomItemDetails = printCustomItemListOptionDetails.Items;
Свойства
ItemDisplayName |
Возвращает или задает отображаемое имя элемента параметра настраиваемой задачи печати. |
ItemId |
Возвращает идентификатор элемента параметра настраиваемой задачи печати. |