- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi All,
I'm after some code to automatically rectangular pattern a work plane along a 3D sketch at a given distance along the 3D sketch.
I have a few to do and don't want to keep clicking and entering the values into Rectangular Pattern dialog box. As typically, only the distance along the 3D sketch changes for the new work plane. Hence, all I want to input is the distance / spacing and the rest does its thing.
I have tried oPartDoc.ComponentDefinition.Features.RectangularPatternFeatures.Add() but errors out:
"Unable to cast object of type 'System.String" to type 'Inventor.ObjectCollection'."
I assume this is the work plane on which it errors out?
This array / rectangular pattern is being done in a part, not an assembly.
Attached is a picture explaining the tick boxes I want hardwired and the variable input I want.
If anyone knows how I can do this let me know.
Cheers,
Jason Snyder
Solved! Go to Solution.