Message 1 of 2
Bend tags need to be Alphabetical instead of Numerical.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi all,
Was hoping someone could help, I'm trying to create a programme to auto create a table for the flat pattern of a specific IDW view. I have gotten as far as the table being created but I'm really struggling with the last bit. I need help to get the Bend ID to have Alphabetical letters instead of Numerical ones. Here is the current code:
Public Sub Main CreateBendTable() ' Reference to the active drawing document Dim oDrawDoc As DrawingDocument oDrawDoc = ThisApplication.ActiveDocument ' Reference to the active sheet Dim oActiveSheet As Sheet oActiveSheet = oDrawDoc.ActiveSheet ' Get path sheetpart Dim oPartDoc As PartDocument oPartDoc = oDrawDoc.ReferencedDocuments.Item(1) ' Create the placement point for the table Dim oPoint As Point2d oPoint = ThisApplication.TransientGeometry.CreatePoint2d(21.5, 19) ' Specify the columns - this can be specified in any combination/order Dim strColumns(0 To 2) As String strColumns(0) = "BEND ID" strColumns(1) = "BEND ANGLE" strColumns(2) = "BEND DIRECTION" ' Create the bend table by specifying the source sheet metal file Dim oBendTable As CustomTable oBendTable = oActiveSheet.CustomTables.AddBendTable(oPartDoc.FullDocumentName, oPoint, "Bend Table", strColumns) ' Select the bend table and execute the "Select Bends to Display" command oDrawDoc.SelectSet.Select(oBendTable) ThisApplication.CommandManager.ControlDefinitions("DrawingTableSelectBendViewCtxCmd").Execute2(False) ' Select the fifth drawing view ThisApplication.CommandManager.DoSelect(oActiveSheet.DrawingViews(5)) End Sub