Bug Watch: Did You Really Change that Drawing?
7 Mar, 2005 By: Steve Johnson CadalystWhen AutoCAD says you've modified a drawing, don't necessarily believe it, reports our bugmeister.
DBMOD, He Be Odd (2000 to 2005 SP1)
Have you ever closed a drawing and had AutoCAD prompt you to save changes, even if you are certain that you haven't changed a thing? AutoCAD has a system variable called DBMOD that records whether the current drawing has been modified since the last save. If DBMOD is anything other than 0, you are prompted to save the changes when you close the drawing or close AutoCAD. It's possible that you have a start-up routine that changes some system variable stored in the drawing, which would set DBMOD to a nonzero value. On the other hand, it's also possible that AutoCAD is just bugging you.
To see this bug, first make sure your drawing window is maximized. That's not the main AutoCAD window, but the drawing window within that window. It doesn't matter if the main AutoCAD window is maximized. Now open a paper/model space drawing in which the current tab is a Layout tab, rather than the Model tab. Check the value of DBMOD. You should find it is 0, as expected. Now open or create any other drawing. It doesn't matter if this second drawing's current tab is a Layout. Check the value of DBMOD in the second drawing. You should find it is also 0, as expected. Now switch back to the first drawing, for example using Ctrl+Tab. Check the value of DBMOD in this drawing. You will find it is now 28! This means AutoCAD thinks you have modified the drawing view in some way, even though you have done nothing but open another drawing. Close the drawing and AutoCAD will prompt you to save changes.
To sum up, if a drawing is open in a Layout tab, opening any other drawing will convince AutoCAD that the previously opened drawing has been modified. For example, if you drag ten paper/model space drawings from Explorer onto the AutoCAD title bar, DBMOD will be 28 in all but the last drawing. If you close AutoCAD without even looking at the drawings, you will still have to answer the "Save changes" question nine times. Although this seems like a minor irritation, it has the potential to mess up some batch processing scripts. It also means that because AutoCAD cries wolf so often, one day you may ignore a prompt to save some important changes.
Workaround: This does not occur if the drawing window is not maximized. However, that is not a great workaround because of the cost in screen space.
Perverted Revert (2000 to 2005 SP1)
Version 8 and above of the Express tools include the Revert command, which restores your drawing to is last-saved state. It does this by closing and reopening the current drawing. If you are in a drawing that has a combined path and name longer than 127 characters, the Revert command will crash with an error like this:
Microsoft Visual Basic
Run-time error '-2145320924 (80210024)
It will not crash AutoCAD, but it will mess up the File menu's most recently used files list by adding a spurious entry that is part of the path name.
Workaround. VBA users can find an alternative Revert on the JTB World site.
UnIntelliMouse
This is not an AutoCAD bug, but it could look like one if you buy the wrong mouse. The wrong mouse, if you're an AutoCAD user, is the Microsoft Intellimouse Explorer 4.0, although the same probably applies to any Microsoft mouse that has the new tilt-wheel feature. The most obvious bug is that the mouse doesn't generate a middle-button double-click, so you can't use that to perform a Zoom Extents in AutoCAD.
Unfortunately, the problems with this mouse go deeper than that. The middle button -- that is, the wheel -- requires very heavy pressure to register a click. As middle-click and middle-double-clicks are heavily used with AutoCAD, this is a fatal flaw. It will not just slow you down; frequent use could quite likely lead to serious medical issues. Mild finger fatigue sets in after a few minutes, and I developed a seriously aching middle finger after a few hours' use.
The tilt wheel cannot be persuaded to do anything useful in AutoCAD other than side-to-side scrolling in file dialog boxes, and appears to be something of a liability. It just makes the wheel feel unstable while zooming. The forwards/backwards wheel movement is rather stiff, especially when compared with the side-to-side looseness of the wheel. In short, the efforts needed to operate the various moving parts of this mouse are grossly mismatched.
Lest you think I have something against Microsoft peripherals, I should point out that I am happily typing this column on a Microsoft keyboard and moving my cursor around using a Microsoft mouse, as I have for most of the past 20 years. But it's a Microsoft keyboard without a frustrating F Lock key, and a Microsoft mouse without that terrible tilt wheel.
For Mold Designers! Cadalyst has an area of our site focused on technologies and resources specific to the mold design professional. Sponsored by Siemens NX. Visit the Equipped Mold Designer here!
For Architects! Cadalyst has an area of our site focused on technologies and resources specific to the building design professional. Sponsored by HP. Visit the Equipped Architect here!