Parts List "Wrap Table at Row" Using VBA (API)

Parts List "Wrap Table at Row" Using VBA (API)

Anonymous
Not applicable
714 Views
3 Replies
Message 1 of 4

Parts List "Wrap Table at Row" Using VBA (API)

Anonymous
Not applicable

I'm writing a macro to reorganize a parts list to a different, non-evenly distributed configuration before exporting the IDW to a DWG/DXF.

 

I need a way to programmatically manipulate (using a VBA macro) the "Wrap Table at Row" property that is accessed by right-clicking on a parts list row in the "Edit Parts List" interface (right-click on the parts list>Edit Parts List).  When the drawing is opened for exporting, the parts list is in a different configuration and I need to remove all of the "Wrap Table at Row"s, with the macro, and replace them in new locations to reorganize the table.

 

I can't find anything on the forums or in the documentation about accessing "Wrap Table at Row" from VBA.

0 Likes
715 Views
3 Replies
Replies (3)
Message 2 of 4

johnsonshiue
Community Manager
Community Manager

Hi! Is the following what you were looking for?

 


PartsList.WrapAutomatically Property

Parent Object: PartsList

 

Description:

 

Gets and sets whether to split the table equally.

 

Syntax:

 

PartsList.WrapAutomatically() As Boolean


Property Value:
This is a read/write property whose value is a Boolean.

 

Many thanks!



Johnson Shiue (johnson.shiue@autodesk.com)
Software Test Engineer
0 Likes
Message 3 of 4

Anonymous
Not applicable

No, that doesn't do quite what I need.  The key thing here is "split the table equally".  I don't want to split the table equally.  I want to be able to wrap the table at any location using my macro just like you can when editing the parts list manually.

 

Thanks for the reply though!

0 Likes
Message 4 of 4

Anonymous
Not applicable

UPDATE:

 

I was not able to find a way to directly mimic the "Wrap Table at Row" behavior that I wanted.

 

I ended up going with my plan B, which was to have the macro copy the parts list and hide the rows that weren't supposed to show up in each of the copies.  That allows me to organize the parts list at will with the macro.  For example I could have the first parts list show items 1-3 the second show 4-8 and the third show 9-26 if that was what was required for the drawing in question.

0 Likes