When using the function of the iPart, how to generate the work axis correctly?

When using the function of the iPart, how to generate the work axis correctly?

Anonymous
Not applicable
395 Views
1 Reply
Message 1 of 2

When using the function of the iPart, how to generate the work axis correctly?

Anonymous
Not applicable

For example, this part in the attachment.

I want to add work axis to every square.

I currently use the array function to generate all the work axes.

But the iPart can't add location features directly in batches.

And the location feature can allow up to 200 parameters.

If I choose the length of parts generated by the iPart to be less than 35 ul, these redundant positioning features will not disappear.

Can you give me a demonstration with iLogic?

Thank you.

TIM图片20190520122821.pnglost work asixlost work asix

ipart pragmaipart pragma

0 Likes
Accepted solutions (1)
396 Views
1 Reply
Reply (1)
Message 2 of 2

JamieVJohnson2
Collaborator
Collaborator
Accepted solution

To define a work axis via Inventor API code, you must:

get the part document:

dim partDoc as PartDocument = (from assembly or from active file, you choose)

get the PartDefinition:

dim cdPart as PartComponentDefinition = partDoc.ComponentDefinition

get the WorkAxes (plural for axis)

cdPart.WorkAxes

Use that to add WorkAxis from one of the many options (such as AddByTwoPlanes):

cdPart.WorkAxes.AddByTwoPlanes(plane1, plane2)

 

 

Jamie Johnson : Owner / Sisu Lissom, LLC https://sisulissom.com/
0 Likes