OrderManager Class

class NXOpen.Drawings.OrderManager

Bases: object

Represents an object that manages orders.

An order represents the way 2D components are presented in the sketch node in the part navigator. There are two types of orders, system and user-defined. System orders cannot be modified. To obtain an instance of this class, refer to NXOpen.Layout2d.ComponentCollection

New in version NX11.0.0.

Methods

Method Description
ApplyOrder Applies the order matching the specified name
CreateNewOrder Creates an order of the 2D Components provided in the list
DeleteOrder Delete the order matching the specified name
GetAvailableOrdersNames Gets all available orders names for specified sketch parent
GetCurrentOrderName Gets the current applied order name
IsSystemOrder Validates the order matching the specified name is system order
RenameOrder Renames the order matching the specified name with the new name provided
Reorder Updates the current order based on the provided list of 2D components if the order is user-defined, and creates a new order otherwide

Method Detail

ApplyOrder

OrderManager.ApplyOrder

Applies the order matching the specified name

Signature ApplyOrder(parentObject, orderName)

Parameters:

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

CreateNewOrder

OrderManager.CreateNewOrder

Creates an order of the 2D Components provided in the list

Signature CreateNewOrder(parentObject, newOrderName, objectsInOrder)

Parameters:

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

DeleteOrder

OrderManager.DeleteOrder

Delete the order matching the specified name

Signature DeleteOrder(parentObject, newOrderName)

Parameters:

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

GetAvailableOrdersNames

OrderManager.GetAvailableOrdersNames

Gets all available orders names for specified sketch parent

Signature GetAvailableOrdersNames(parentObject)

Parameters:parentObject (NXOpen.Sketch) –
Returns:
Return type:list of str

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

GetCurrentOrderName

OrderManager.GetCurrentOrderName

Gets the current applied order name

Signature GetCurrentOrderName(parentObject)

Parameters:parentObject (NXOpen.Sketch) –
Returns:
Return type:str

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

IsSystemOrder

OrderManager.IsSystemOrder

Validates the order matching the specified name is system order

Signature IsSystemOrder(parentObject, orderName)

Parameters:
Returns:

Return type:

bool

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

RenameOrder

OrderManager.RenameOrder

Renames the order matching the specified name with the new name provided

Signature RenameOrder(parentObject, orderName, newOrderName)

Parameters:
  • parentObject (NXOpen.Sketch) –
  • orderName (str) –
  • newOrderName (str) –

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)

Reorder

OrderManager.Reorder

Updates the current order based on the provided list of 2D components if the order is user-defined, and creates a new order otherwide

Signature Reorder(parentObject, objectsInOrder)

Parameters:

New in version NX11.0.0.

License requirements: nx_layout (“NX Layout”)