REvision Table Locating

REvision Table Locating

Anonymous
Not applicable
413 Views
1 Reply
Message 1 of 2

REvision Table Locating

Anonymous
Not applicable

I am having an issue with having the revision table and some of the other types of table we have on our title block to move with the border if the sheet size changes. Is there a code to write or a way to constrain the table to an existing point?
Any ideas will be helpful! Thanks! 🙂

0 Likes
414 Views
1 Reply
Reply (1)
Message 2 of 2

Jon.Balgley
Alumni
Alumni

Hi --

 

The following rule will put the revision table into the upper-right corner of the active sheet.  Is that enough to solve your problem?  Let  me know if you need more details.  Note there are some assumptions (table name, use of X-coord, negative offset).

 

Also, I am not sure about the best way to trigger it.  You can certainly run it manually.

 

 

SyntaxEditor Code Snippet

Dim oTG As TransientGeometry = ThisApplication.TransientGeometry


Dim sht As Sheet = ActiveSheet.Sheet

tableName = "Revision History"

Dim revTab As RevisionTable = sht.RevisionTables.Item(tableName)

Dim rbox As Box2D
rbox = revTab.RangeBox
tabWidth = rbox.maxPoint.x - rbox.minPoint.x

Dim brdr As Border
brdr = sht.Border

Dim newPos as Point2d = brdr.rangebox.maxPoint.Copy
Dim offset As Vector2d = oTG.CreateVector2D(-tabWidth, 0)
newPos.TranslateBy(offset)

revTab.position = newPos

 


Jon Balgley
0 Likes