07-19-2022
02:36 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
07-19-2022
02:36 AM
Hi koenroovers
if i understand you correctly you would like to have the parts list on the left side of your drawing right above the title block, right?
I looked a little bit around on the forum and found this
the code Turac posted seem to place the parts list right above the title block, at least on my drawing (tried to change size to A0 and back to A3) and the parts list jumped straight to the left corner right above the title block
Dim oDrawDoc As DrawingDocument
oDrawDoc = ThisApplication.ActiveDocument
Dim oSheet As sheet
oSheet = oDrawDoc.ActiveSheet
Dim oPartslist As Partslist
oPartsList = oDrawDoc.ActiveSheet.PartsLists.Item(1)
Dim oPlacementPoint, oPlacementPoint2 As point2d
Dim oBorder As Border
oBorder = oSheet.Border
PartHight=oSheet.PartsLists.Item(1).RangeBox.MaxPoint.Y-oSheet.PartsLists.Item(1).RangeBox.MinPoint.Y
TitleY=oSheet.TitleBlock.RangeBox.MaxPoint.Y
PointX=oBorder.Rangebox.Maxpoint.x
PointY=TitleY+PartHight
oPlacementPoint = ThisApplication.TransientGeometry.CreatePoint2d(PointX,PointY)
oPartslist.position = oPlacementPoint