US$0.00
0

A Simple Macro for All SolidWorks Delete Dangling Dimensions Automated!

Reattaching Dangling Dimensions - 2024 - What's New in SOLIDWORKS

If you’ve been working a while in SOLIDWORKS, you know the drill. You open a drawing, and there they are: those hanging, useless dimensions that lost their reference points. They’re referred to as dangling dimensions, and one or two will not hurt anything, but a whole group can take a neat drawing and make it into a confusing mess. They’re not just visual eyesores; they’re an early symptom of unwanted errors.

But what if you could nuke them all in one click? Well… now you can, by following along with this guide. This guide is going to explore a simple macro for all SolidWorks delete dangling dimensions. You can utilize a simple, convenient macro that addresses this very problem by zapping all your dangling dimensions for you.

Key Features

  • Deletes all dangling dimensions from active drawings.
  • Works with any SOLIDWORKS version, thanks to late-binding.
  • User confirmation required before deletion.

How The Macro Works Behind the Scenes?

The VBA macro follows a clear, logical route to make sure that it only targets what you want it to. Here’s a step-by-step breakdown of how it works:

  • It Checks for the Document: It first checks whether the current document is a drawing. If you have something open like an assembly or a part, it will warn you and terminate, so you don’t even use it where it shouldn’t be used. This is also a good thing to keep in mind if you ever wonder how to cancel macros inc before they land you in trouble.
  • It Scans for Dangles: The macro searches every view in your drawing, looking for any annotations SOLIDWORKS has tagged as “dangling.” It only calls out those dimensions that have lost their reference.
  • It Asks for Authorization: You get a message of approval prior to deletion being done. That is your final chance to approve the action and prevent modifications from being inadvertently made, which is really a great safety feature, especially if you are working on something intricate and would like to prevent modifications from being made by accident, as if you have to delete configuration SolidWorks drawings in a particular way.
  • It’s Version-Agnostic: Because it uses late-binding, the macro does not use explicit references and works perfectly across different versions without your involvement in code.es and works perfectly across different versions without your involvement in code.

Code:

Bottom Line

Should you need to automate your SOLIDWORKS workflows even further, from dimension management to automating other drawing processes, Blue Byte Systems Inc. is here to help. We specialize in custom add-ins and automation utilities designed to your specifications. Contact us today!

Author

Amen Jlili

Amen Jlili is the founder and technical director of Blue Byte Systems Inc., a software company in Vancouver, Canada, specializing in automating SOLIDWORKS and PDM. With over a decade of experience, he has authored several courses and open-source frameworks related to the SOLIDWORKS API. His leadership ensures that Blue Byte Systems prioritizes customer satisfaction and delivers high-quality software and CAD design solutions.
0
    0
    Your Cart
    Your cart is emptyReturn to Shop
    ×