Showing results for 
Search instead for 
Did you mean: 

ExtrudedCutout() using multiple profiles always fails

Solution Partner Pioneer Solution Partner Pioneer
Solution Partner Pioneer

Please look at this basic extruded cutout, that DO WORKS as expected:


Set oProfiles = PartDoc.Sketches(1).Profiles

Set oProfile = oProfiles(1)

Set oModel = PartDoc.Models(1)


oModel.ExtrudedCutouts.AddFinite(oProfile, igLeft, igBoth, dHeight)


So far so good, when the first sketch contains a single profile, as example a rectangle.


Now, suppose the sketch contains not one BUT TWO not-intersecting rectangles


Interactively, you can pick both of them and perform the cutout.


If you attempt to do the same using the code above, THE FEATURE FAILS.


You can enter into editing the feature as well, just for confirming the geometry, then hit finish, and the feature will be validated successfully as expected.


I am puzzled.


How can i make the ExtrudedCutouts.AddFinite() API work if the profile contains multiple chains ?


I also have made some experiments using .AddFiniteMulti() Method but without success.


The sketch.profiles object reports ONE single profile even if there are multiple loops (ie. some cricles), and i can't understand how to split them into a vector to feed .AddFiniteMulti() API, assuming the .AddFinite() is limited to a single profile and i really need the "multi" version to achieve a successful multiple cutout.


Anyone wishing to help me ?


Paolo Marani



Re: ExtrudedCutout() using multiple profiles always fails


Try using: