Skip to main content

PrintBarManager.GetBarItemByCommand(PrintingSystemCommand) Method

Provides access to a bar item corresponding to the specified command.

Namespace: DevExpress.XtraPrinting.Preview

Assembly: DevExpress.XtraPrinting.v26.1.dll

NuGet Package: DevExpress.Win.Printing

Declaration

public BarItem GetBarItemByCommand(
    PrintingSystemCommand command
)

Parameters

Name Type Description
command PrintingSystemCommand

A PrintingSystemCommand enumeration value, specifying the command corresponding to the bar item in question.

Returns

Type Description
BarItem

A BarItem object, specifying the bar item corresponding to the specified command.

Remarks

Each printing system command corresponds to a bar item representing this command in Print Preview GUI.

This method searches the collection for the first bar item executing the specified command and returns this item. When a matching bar item is not found, this method returns an empty BarItem object.

See Also