Community
Inventor Programming - iLogic, Macros, AddIns & Apprentice
Inventor iLogic, Macros, AddIns & Apprentice Forum. Share your knowledge, ask questions, and explore popular Inventor topics related to programming, creating add-ins, macros, working with the API or creating iLogic tools.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

insert revision table at a specific point

3 REPLIES 3
SOLVED
Reply
Message 1 of 4
Miguel.CarvajalS34Q6
310 Views, 3 Replies

insert revision table at a specific point

I apologize for being so repetitive, I need to automatically insert the revision table in each drawing sheet, but when doing so the table adopts a position that is not adequate (see image). the board is inserted too far away and interferes with the sign frame. How can I insert it by defining a point .

Labels (4)
3 REPLIES 3
Message 2 of 4

Hi @Miguel.CarvajalS34Q6 

Can you attach the code your using? It looks like you need just to offset in both x and y direction from the border corner position. 

If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan
Message 3 of 4

this is the code i am using

Dim doc As DrawingDocument = ThisDoc.Document
Dim sheet As Sheet = doc.ActiveSheet

Dim position = sheet.Border.RangeBox.MaxPoint

Dim table = Sheet.RevisionTables.Add2(position, True)

Dim tableWith = table.RangeBox.MaxPoint.x - table.RangeBox.MinPoint.x
position.X = position.X - tableWith

table.Position = position
Message 4 of 4

Dim doc As DrawingDocument = ThisDoc.Document

Dim sheet As Sheet = doc.ActiveSheet

Dim position As Point2d = sheet.Border.RangeBox.MaxPoint

Dim table As RevisionTable = sheet.RevisionTables.Add2(position, True)

Dim tableWidth As Double = table.RangeBox.MaxPoint.X - table.RangeBox.MinPoint.X

Dim gap As Double = 0.9

' Get a new position in X direction 
position.X = position.X - tableWidth - gap
' Get a new position in Y direction 
position.Y = position.Y - gap

' Set the table to this new position.
table.Position = position
If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report