pycatia.drafting_interfaces.drawing_sheets¶
Module initially auto generated using V5Automation files from CATIA V5 R28 on 2020-06-11 12:40:47.360445
Warning
The notes denoted “CAA V5 Visual Basic Help” are to be used as reference only. They are there as a guide as to how the visual basic / catscript functions work and thus help debugging in pycatia.
- class pycatia.drafting_interfaces.drawing_sheets.DrawingSheets(com_object)¶
Note
CAA V5 Visual Basic Help (2020-06-11 12:40:47.360445)
System.IUnknownSystem.IDispatchSystem.CATBaseUnknownSystem.CATBaseDispatchSystem.CollectionDrawingSheetsA collection of all the drawing sheets currently managed by the drawingdocument.Warning: This interface is not available with 2D Layout for 3DDesign.- property active_sheet: DrawingSheet¶
Note
- CAA V5 Visual Basic Help (2020-06-11 12:40:47.360445)
- o Property ActiveSheet() As DrawingSheet (Read Only)Returns the active drawing sheet of the drawing document.Warning: This method is not available with 2D Layout for 3DDesign.Example:The following example retrieves in SheetToWorkIn the active drawingsheet of the drawing document named CATDrawing1.Dim MyDrawingDoc As DocumentSet MyDrawingDoc = CATIA.Documents.Item(“CATDrawing1”)Dim SheetToWorkIn As DrawingSheetSet SheetToWorkIn = MyDrawingDoc.Sheets.ActiveSheet
- Return type:
- add(i_drawing_sheet_name: str) DrawingSheet ¶
Note
- CAA V5 Visual Basic Help (2020-06-11 12:40:47.360445))
- o Func Add(CATBSTR iDrawingSheetName) As DrawingSheetCreates a drawing sheet and adds it to the DrawingSheets collection. Thisdrawing sheet becomes the active one.Warning: This method is not available with 2D Layout for 3DDesign.Parameters:iDrawingSheetNameThe name to assign to the created DrawingSheet objectReturns:The created drawing sheetExample:The following example creates a drawing sheet named FirstSheet andretrieved in MySheet in the drawing sheet collection of the document namedCATDrawing1.Dim MyDrawingDoc As DocumentSet MyDrawingDoc = CATIA.Documents.Item(“CATDrawing1”)Dim MySheet As DrawingSheetSet MySheet = MyDrawingDoc.Sheets.Add(“FirstSheet”)
- Parameters:
i_drawing_sheet_name (str) –
- Return type:
- add_detail(i_drawing_sheet_name: str) DrawingSheet ¶
Note
- CAA V5 Visual Basic Help (2020-06-11 12:40:47.360445))
- o Func AddDetail(CATBSTR iDrawingSheetName) As DrawingSheetCreates a detail drawing sheet and adds it to the DrawingSheets collection.This detail drawing sheet becomes the active one.Warning: This method is not available with 2D Layout for 3DDesign.Parameters:iDrawingSheetNameThe name to assign to the created detail DrawingSheet objectReturns:The created drawing sheetExample:The following example creates a detail drawing sheet named FirstSheetand retrieved in MySheet in the drawing sheet collection of the document namedCATDrawing1.Dim MyDrawingDoc As DocumentSet MyDrawingDoc = CATIA.Documents.Item(“CATDrawing1”)Dim MySheet As DrawingSheetSet MySheet = MyDrawingDoc.Sheets.Add(“FirstSheet”)
- Parameters:
i_drawing_sheet_name (str) –
- Return type:
- item(i_index: cat_variant) DrawingSheet ¶
Note
- CAA V5 Visual Basic Help (2020-06-11 12:40:47.360445))
- o Func Item(CATVariant iIndex) As DrawingSheetReturns a drawing sheet using its index or its name from the DrawingSheetscollection.Warning: This method is not available with 2D Layout for 3DDesign.Parameters:iIndexThe index or the name of the drawing sheet to retrieve from thecollection of drawing sheets. As a numerics, this index is the rank of thedrawing sheet in the collection. The index of the first drawing sheet in thecollection is 1, and the index of the last drawing sheet is Count. As a string,it is the name you assigned to the drawing sheet using theAnyObject.Name property or when creating it using the Add method.Returns:The retrieved drawing sheetExample:This example retrieves in ThisDrawingSheet the third drawing sheet, andin ThatDrawingSheet the drawing sheet named MySheet in the drawing sheetcollection of the active document, supposed to be a drawingdocument.Dim ThisDrawingSheet As DrawingSheetSet ThisDrawingSheet = CATIA.ActiveDocument.Sheets.Item(3)Dim ThatDrawingSheet As DrawingSheetSet ThatDrawingSheet = CATIA.ActiveDocument.Sheets.Item(“MySheet”)
- Parameters:
i_index (cat_variant) –
- Return type:
- remove(i_index: cat_variant) None ¶
Note
- CAA V5 Visual Basic Help (2020-06-11 12:40:47.360445))
- o Sub Remove(CATVariant iIndex)Removes a drawing sheet from the DrawingSheets collection.Warning: This method is not available with 2D Layout for 3DDesign.Parameters:iIndexThe index or the name of the drawing sheet to remove from thecollection of drawing sheets. As a numerics, this index is the rank of thedrawing sheet in the collection. The index of the first drawing sheet in thecollection is 1, and the index of the last drawing sheet is Count. As a string,it is the name you assigned to the drawing sheet using theAnyObject.Name property or when creating it using the Add method.Example:The following example removes the second drawing sheet and the drawingsheet named SheetToBeRemoved in the drawing sheet collection of the activedocument, supposed to be a drawing document.CATIA.ActiveDocument.DrawingSheets.Remove(2)CATIA.ActiveDocument.DrawingSheets.Remove(“SheetToBeRemoved”)
- Parameters:
i_index (cat_variant) –
- Returns:
None