• Skip to main content
  • Skip to primary sidebar
  • Skip to footer
blog.draftsperson.net

blog.draftsperson.net

the art of technical drawing

blog.draftsperson.net

DIMROTATE LISP: Flip Upside-Down Dimensions in AutoCAD

August 1, 2007

Last updated July 28, 2026

Dimension text ends up upside down more often than it should. You dimension between two points, pick them in the order that felt natural, and the text reads back to front. AutoCAD will not simply flip it for you, and redrawing the dimension to get it the right way up is a poor use of a morning.

DIMROTATE flips them. Select any number of upside-down dimensions, and it rotates each by 180 degrees in place. The dimension keeps its associativity, its style and its measured value — only its reading direction changes.

Dimensions on a drawing reading upside down before the DIMROTATE routine is run
Before running Dimrotate Lisp routine
The same dimensions reading the right way up after DIMROTATE has flipped them
After running Dimrotate Lisp routine

What it does in practice

Every dimension entity carries a stored direction that controls which way its text reads. The routine reaches into each selected dimension, subtracts 180 degrees from that value, and writes it back. Because it edits the dimension’s own definition rather than exploding it or drawing new text on top, the result is still a real dimension: it still updates if the geometry moves, still obeys its dimension style, and still reports the true measurement.

It works on a selection, not one at a time, so a whole row of dimensions along the bottom of a detail can be fixed in one go. It reports its progress on the command line as it works through them, and it wraps the whole operation in an undo group, so one U puts everything back if you selected the wrong ones.

Because the operation is a straight 180-degree subtraction, running it twice on the same dimension returns it to where it started. That makes it safe to experiment with: if you flip something that did not need flipping, run it again on that dimension.

Select linear dimensions only

The one thing that will trip you up. The selection filter accepts every kind of dimension — linear, aligned, radial, diameter, angular, ordinate — but the value it modifies only exists on the linear and aligned ones. It is the direction the dimension line runs, and a radius or an angular dimension has no such thing.

Include a radial or angular dimension in your selection and the routine will stop with a type error partway through. Anything it had already processed stays flipped, so you are not left with a mess, but the run is incomplete. Window-select carefully on a detail that mixes dimension types, or use a fence along the row you actually want.

One small note for anyone loading a lot of routines: this file also defines a degrees-to-radians helper under the very common name DTR, without a command prefix. If another of your routines defines its own DTR differently, whichever loads last wins. Both are almost certainly the same one-line conversion, so it rarely matters, but it is the kind of thing worth knowing about.

Command reference

The file defines a single command, DIMROTATE.

How to load it

Unzip the download and load dimrotate.lsp with APPLOAD, or add it to the Startup Suite — this is the sort of small fix-up command that is only useful if it is already there when you need it. No support files. Our AutoLISP guide covers loading.

Step-by-step usage

  1. Type DIMROTATE.
  2. Select the upside-down dimensions. Stick to linear and aligned ones, as explained above.
  3. Press Enter. It counts through them on the command line as it goes.
  4. Check the result. If you flipped one that did not need it, run the command again on that one.

Compatibility notes

The listing records it as working on AutoCAD 2006, 2007 and 2019, which is a good span. It edits entity data directly rather than driving commands, and the dimension data it touches has not changed, so it is a reasonable bet on current releases too.

It is plain AutoLISP with no dialog boxes and no Express Tools calls, so nothing in it requires the full product; LT users on LT 2024 or later, the release that brought AutoLISP to LT, should be able to run it. See what runs on AutoCAD LT. It modifies dimensions in place, so run it on a copy the first time.

Download

Name: Dimrotate
Description: Upside down dimension? don’t want to waste time re-drawing it!
Try dimrotate, a simple lisp routine to rotate dimensions 180 degrees.
Type: AutoCAD AutoLISP Routine
Author: Anon
File Size: 32 Kb
Cost: Free
Worked on: AutoCAD 2006, 2007, 2019
Download File: Dimrotate.lsp

Related routines

  • Add or subtract text — adjust numeric values in text you have already placed.
  • LLP Suite — includes a set of dimension checking and fitting commands.
  • Best of LISP collection — general drafting utilities.

References

  • AutoLISP: the complete guide
  • Free LISP routines library
  • AutoLISP on AutoCAD LT

Filed Under: AutoLISP Routines

Primary Sidebar

Subscribe to our Youtube Channel

Post CAD drafting jobs on Freelancer.com. and get some free money to do this.

Categories

  • American Steel Industry (4)
  • AutoCAD Articles & Reference (30)
  • AutoCAD Bugs & Problems (19)
  • AutoCAD Tips (29)
  • AutoCAD Tutorials (54)
  • AutoLISP Routines (328)
  • AutoLISP Tutorials (15)
  • CAD Standards (7)
  • Civil 3D (7)
  • Civil Drafting (4)
  • Dimensions (2)
  • Drafting Funnies (71)
  • Drafting History (9)
  • Drafting Standards (84)
  • Electrical Drafting (2)
  • General IT reference (7)
  • Geometry (15)
  • GIS (2)
  • Hatch Patterns (12)
  • Office Life Hacks (3)
  • PT (1)
  • Revit Tutorials (54)
  • Steel Detailing (14)
  • Structural Drafting (26)
  • Technical Dictionary (61)
  • Useful Website Links (19)

Footer

Free downloads

  • Free AutoLISP routines
  • Free hatch patterns
  • SHX fonts & text styles
  • Numbering LISP collection
  • ISO 3098B font

Reference charts

  • AWS weld symbols chart
  • Steel detailing chart
  • Hole & slot sizes
  • Bolt edge distance
  • ANSI & ARCH paper sizes
  • How to fold an A1 drawing

Useful links

  • CAD blocks (DWG)
  • Revit families
  • structuraldrafter.com
  • cad-corner.com
  • About
  • Privacy policy

Provided for free with no warranty · Log in