Automatically Leader the Point Labels When Placing a Coordinate Dimension Table
Automatically Leader the Point Labels When Placing a Coordinate Dimension Table
(OP)
Can this be done? When we create the Coordinate Dimension Table, each point gets a text label next to it, but no leader. We always have to go back through all of the points and use the Add Leader command on each text label and click the respective point.
Is there a style setting in the Standards or an Option that I'm missing to turn on automatic leaders to these texts?
Is there a style setting in the Standards or an Option that I'm missing to turn on automatic leaders to these texts?





RE: Automatically Leader the Point Labels When Placing a Coordinate Dimension Table
CODE -->
Sub CATMain() Dim oDrw As DrawingDocument Set oDrw = CATIA.ActiveDocument For i = 1 To oDrw.Selection.Count On Error Resume Next Dim oText As DrawingText Set oText = oDrw.Selection.Item(i).Value If oText.Leaders.Count = 0 Then Set oPoint = oText.AssociativeElement Dim arra(1) oPoint.GetCoordinates arra oText.Leaders.Add arra(0), arra(1) End If Next On Error GoTo 0 End SubHope it helps,
Calin
RE: Automatically Leader the Point Labels When Placing a Coordinate Dimension Table
RE: Automatically Leader the Point Labels When Placing a Coordinate Dimension Table
1. Select your texts
2. Run the script.
3. That's it: leaders are going to be created automatically so you won't lose time doing them.
Hope that's clearer,
Calin