I'm trying to make a macro to draw a rectangle with filletsand it's becoming a minor nightmare. Nothing is easy about makingmacros in SW.
I've got it to work somewhat, but you can't use the the fillet toolwhile your recording the macro cause you just get a seperatedimension for each corner of the rectangle. So I used the tangentarc command to do it, then added all the relations. In the editor Iremoved the names of the entities (cause the entity names willalways be different if this rectangle is not the first thing youdraw in a sketch) so now the "SelectById2" command has to go bypick position to select the drawn entities to add the relations.Some of these picks don't work when the Macro runs, and worse, itonly works if your drawing the rectangle on the "Top" plane as thepicks use xyz coordinates and not sketch coordinates. Running thisMacro on the Right plane gives you garbage. I can't find a "Sketch"object in SW that just runs in a 2-D space.
Am I missing something obvious or is this just not doable?SolidworksApi macros








I've got it to work somewhat, but you can't use the the fillet toolwhile your recording the macro cause you just get a seperatedimension for each corner of the rectangle. So I used the tangentarc command to do it, then added all the relations. In the editor Iremoved the names of the entities (cause the entity names willalways be different if this rectangle is not the first thing youdraw in a sketch) so now the "SelectById2" command has to go bypick position to select the drawn entities to add the relations.Some of these picks don't work when the Macro runs, and worse, itonly works if your drawing the rectangle on the "Top" plane as thepicks use xyz coordinates and not sketch coordinates. Running thisMacro on the Right plane gives you garbage. I can't find a "Sketch"object in SW that just runs in a 2-D space.
Am I missing something obvious or is this just not doable?SolidworksApi macros