AnsweredAssumed Answered

Macro dimensions

Question asked by Shane Pickup on Aug 24, 2017
Latest reply on Sep 21, 2017 by John Stoltzfus

Hi Everyone.

 

I'm struggling learning vba so I take my hat off to you people who know your stuff and help people like me.

 

Ive been trying to record a macro to create a basic cabinet door from scratch.  I plan to create a userform so the user can input sizes which then draws the cabinet door and depending on the size suspresses some features.  The macro seems to work ok until it gets to the third dimension on the second sketch (goes from one of the lines of a rectangle in a sketch to an edge of the top face of an extruded part which the sketch is on.

 

The macro sketchs, dimensions and extrudes the outline of the door Ok.

The macro then sketches and dimensions a shape (lock cutout) on the top face of the extruded part which I intend to extrude cut.  Before I extrude cut the sketch I wanted to add locating dimensions from the edges of the extruded part so I could move the feature depending on size of the door.

 

As soon as the macro hits the first locating dimension it stops and errors.

 

Is it because the dimension is to something that is not in the sketch or to two entities?

 

  Can anybody help me understand why this is happening and/or advise a solution.

 

Regards

 

Shane

Outcomes