Skip to content

The AFDIM command

AFDIM adds one command to AutoCAD®, AFDIM, and a ribbon tab named AFDIM with two buttons. The button names are in English in every language. Their tooltips follow the language of AFDIM.

Ribbon buttonWhat it does
DimensionRuns AFDIM.
SettingsOpens the settings dialog. An orange dot on the button means an update needs your attention; see Updates.

The settings dialog has no command of its own. Open it with the Settings button, or type S at the AFDIM selection prompt.

Everything else is on the About tab of the settings dialog. The other tabs hold the dimensioning options; see Settings.

TaskOn the About tabSee
Check for or install an updateUpdates group: Check now, Update nowUpdates
Go back to the version you had before an updateUpdates group: Go back to <version>, shown only after an in-app updateUpdates
Start a trial, enter a licence key, request or load a licence, buy or renewLicence group: Start 7-day trial, Enter licence key…, Request licence, Load licence…, Buy / RenewActivate a licence, Start a 7-day trial
Move a licence key to another computerMove licence to another computer…Move to another computer
Create a support zip, or export the geometry of the last runSupport group: Create support zip…, Export the last run’s geometry…Support bundle
Uninstall AFDIMRemove AFDIM group: Remove AFDIM from this computer…Uninstall

Every question AFDIM asks is a window with buttons, in the language of the settings dialog. Closing a window, or pressing Esc, is the same as its cancel or decline button. Nothing is written or installed.

The language list is a drop-down list at the right end of the header of the settings dialog. The list has 56 languages. Each language appears under its own name, for example “Deutsch” or “日本語”. The list is sorted A–Z by the English name of the language and shows no flags.

A new installation starts in English. It starts in Vietnamese when Windows is set up for Vietnam (its display language, regional format or country). The language you choose applies to the settings dialog, to every notice window and to the command-line messages. Text that is not translated yet appears in English. The translations other than English and Vietnamese are drafts. The language setting changes only the text inside AFDIM.

In Vietnamese you see these labels:

English labelVietnamese label
Settings (name of the settings dialog in messages)Cài đặt
About (settings tab)Về AFDIM
Drawing units: (General tab)Đơn vị bản vẽ:
Automatic (from the current drawing)Tự động (theo bản vẽ đang mở)
Millimetres (mm)Milimét (mm)
InchesInch
Welcome to AFDIM (window, first run)Chào mừng bạn đến với AFDIM
AFDIM is not activated (window)AFDIM chưa được kích hoạt
Start 7-day trialDùng thử 7 ngày
ActivateKích hoạt
Buy / RenewMua / Gia hạn
CloseĐóng

The title bar of the settings dialog reads AFDIM Settings in every language.

Each message that AFDIM prints on the command line starts with [AFDIM]. In Vietnamese they are written without accents. This page quotes the English messages. The only keyword on the command line is Setting, at the AFDIM selection prompt, in every language.

AFDIM adds dimensions to a part. See Quick start for the full workflow.

Before anything else, even before the licence, AFDIM checks that its own program files are the ones its release shipped. When they are not, it draws nothing, prints one line and opens a window. AutoCAD stays open.

Command lineWindowWhat to do
[AFDIM] Cannot run: the AFDIM program files on this computer are not intact. Reinstall AFDIM from afdim.com.AFDIM needs to be reinstalled, with Open the download page and CloseA program file is damaged, changed or missing, or a DLL or EXE that AFDIM did not ship sits in its program folder. Reinstall AFDIM from Download.
[AFDIM] Cannot run: another program is holding the AFDIM program files. Run AFDIM again.AFDIM could not check its program files, with CloseAnother program, often an antivirus scan, is holding the files. Run AFDIM again.

See AFDIM needs to be reinstalled.

AFDIM does not run. The command line prints one line:

[AFDIM] Cannot run: <reason> Activate it in Settings > About.

<reason> says why. On a new installation it is AFDIM is not activated. Other examples are the licence has expired. and this version was released after the licence's update period. The last one applies to a perpetual licence and a version released after the end of its updates; see Renew the updates of a perpetual licence. Troubleshooting lists every reason.

A window then shows the licence status and what to do. On a computer that has never had a licence, the window is titled Welcome to AFDIM and offers the free 7-day trial. Otherwise it is titled AFDIM is not activated. Its buttons, in this order:

ButtonWhat it does
Start 7-day trialDimmed when this computer has already used its 7-day trial. Activate is then the highlighted button. See Start a 7-day trial.
ActivateOpens the settings dialog on the About tab. See Activate a licence.
Buy / RenewOpens, in your browser, the renewal address written in your licence. When the licence has none, it opens the Licence page, afdim.com/account/.
CloseCloses the window.

AFDIM keeps its settings in %APPDATA%\AFDIM\settings.json. Two things can stop it from reading that file:

  • The file is damaged. AFDIM keeps a copy of it as settings.json.corrupt and goes back to the default settings. The next time you open the settings dialog or run AFDIM, a window titled AFDIM settings were reset to defaults says so and shows where the damaged file is kept. When an earlier save exists, the window also names settings.json.bak in the same folder. The window comes back until you press OK. Then open the settings and set your dimension layer, tolerances and templates again before you dimension further.
  • Another program is holding the file. The settings dialog does not open. A window titled Settings could not be opened tells you so. AFDIM does not run either, and prints:
[AFDIM] Cannot run: the settings file is in use by another program and could not be read. Your settings are untouched - try again in a moment.

Your settings are not changed. Try again in a moment.

If objects are already selected when you start AFDIM, it uses them and does not prompt. Otherwise it prompts:

Select the part to dimension or [Setting]

When AutoCAD multiplies linear measurements (DIMLFAC is not 1), the prompt starts with a warning:

(! DIMLFAC = <value>: measurements will be scaled) Select the part to dimension or [Setting]

<value> is the factor that AutoCAD applies to measurements in the current space.

OptionWhat it does
(select)Window-select or pick the part, then press Enter.
SettingType S and press Enter, or click Setting. Opens the settings dialog. When you close it, you are back at the selection prompt.

The selection accepts LINE, ARC, CIRCLE, ELLIPSE, LWPOLYLINE, POLYLINE, SPLINE, INSERT and REGION.

In a Layout tab, you can select objects that are drawn directly on the paper in the usual way. AFDIM does not select model-space objects through a viewport while you are on the paper.

To dimension a part that is inside a viewport, double-click inside the viewport to activate it. Then run AFDIM. In an activated viewport, AFDIM works in model space. When DIMSCALE is 0, AFDIM uses the scale of the viewport.

If you are on the paper, outside every viewport, and the selection is empty, the command line prints:

[AFDIM] Nothing selected. If the part is inside a viewport, double-click inside it and run AFDIM again.

Follow the advice in the message. AFDIM does not print this line after Esc, in the Model tab or in an activated viewport. There, an empty selection ends the command without a message.

Press Esc while AFDIM is working to stop it. Nothing is written, and the command line says:

[AFDIM] Cancelled (ESC). The drawing is unchanged.

A large drawing can take a while. When a run is still working after 3 seconds, AFDIM says so once:

[AFDIM] Large drawing, still working... Press ESC to cancel.

AFDIM checks the licence again while it works and before it writes. If that check fails, the whole run is discarded and nothing is written to the drawing. The command line says which case it was:

MessageMeaning and what to do
[AFDIM] The licence could not be confirmed during the run. This run's output was discarded; run AFDIM again.The licence could not be confirmed while AFDIM was working, for example because another program held the licence file or a renewal had just replaced it. The licence is valid again now: run AFDIM again.
[AFDIM] The licence is no longer valid. Nothing was written.The licence stopped being valid during the run, for example because it expired. See AFDIM refuses to run.
[AFDIM] The licence is no longer valid. This run's output was discarded.The same, found just before the dimensions were saved to the drawing.

The command line only reports results and things you may need to act on.

Every run prints one result line:

MessageMeaning
[AFDIM] Wrote <n> dimension(s) + <m> callout(s) on layer "<layer>".AFDIM wrote <n> dimensions and <m> callouts on layer <layer>.
[AFDIM] No dimensions were produced.AFDIM wrote no dimension, callout or centreline. See Troubleshooting.

These lines appear only when they apply:

MessageMeaning and what to do
[AFDIM] WARNING: no CLOSED outline found. Usually some lines do not meet (zoom into the corners, or JOIN/PEDIT them). If you are sure it is closed, send it to support: Settings > About > Support > Export the last run's geometry.AFDIM found no closed profile, usually because curves do not meet. Zoom into the corners, or join the curves with JOIN or PEDIT. If you are sure the outline is closed, send the part to support: Settings › About › Export the last run’s geometry…. See Support bundle.
[AFDIM] WARNING: <n> separate parts selected; only the LARGEST was dimensioned. Run AFDIM again for: <w>x<h>, <w>x<h>, <w>x<h> (+<more>).You selected <n> separate parts, and AFDIM dimensioned only the largest. The line gives the width x height, in drawing units, of up to three skipped parts. (+<more>) is the number of further skipped parts; it appears only when more than three were skipped. Run AFDIM once for each part.
[AFDIM] WARNING: layer "<layer>" is OFF, so the dimensions just written are NOT VISIBLE. Turn it on with the LAYER command.The layer of the new dimensions is off, so you cannot see them. When the layer is frozen, the line reads FROZEN instead of OFF. AFDIM does not switch your layers on. Turn the layer on, or thaw it, with LAYER.
[AFDIM] WARNING: <n> analysis step(s) failed, some dimensions may be MISSING. Send the drawing to support: Settings > About > Support > Export the last run's geometry.<n> analysis steps failed, so dimensions may be missing. Send the part to support: Settings › About › Export the last run’s geometry…. See Support bundle.
[AFDIM] WARNING: <n> dimension/callout write(s) failed, some dimensions may be MISSING. Send the drawing to support: Settings > About > Support > Export the last run's geometry.AutoCAD refused to write <n> dimensions or callouts, so some may be missing. Send the part to support: Settings › About › Export the last run’s geometry…. See Support bundle.
[AFDIM] ERROR: AFDIM stopped part-way (<error>). Nothing was written, so the drawing is unchanged. Send the log: Settings > About > Support > Create support zip.The run stopped on an unexpected error. <error> is the type of the error, a colon and the error message. Nothing was written. Send support a support bundle: Settings › About › Create support zip….
[AFDIM] Version <version> was installed by the last update and has not completed a run yet. If this error started with the update: Settings > About > Go back to <previous>.This line follows one of the three lines above. It appears when an in-app update installed version <version>, no run has finished without a failure since then, and there is a previous version to go back to. If the problem started with the update, go back to <previous>; see Updates.
[AFDIM] Dimension layer "<layer>" was created — <reason>.This run created the dimension layer <layer> because your drawing did not have it. <reason> is the layer you picked (not in this drawing, re-created from the saved settings). AFDIM created the layer with the look that it saved in the settings.
[AFDIM] Centrelines drawn on layer "<layer>" (just created) — <reason>.This run created the centreline layer <layer>. <reason> says why. Either AFDIM re-created the layer you picked in the settings, or it created AFDIM_CENTER because the wanted layer would draw centrelines as solid lines. In the second case, <reason> names the wanted layer, for example the CENTERLAYER variable ("0") has no broken centreline linetype. See Settings.
[AFDIM] Skipped <n> object(s) that are not lines or curves (<kinds>).<n> selected objects are not drawing curves, so AFDIM skipped them. <kinds> lists up to four object types with a count each, for example TEXT x3, and ends with ... when there are more types.
[AFDIM] Skipped <n> line(s) that are not part of a closed outline (not dimensioned).<n> curves are not part of a closed profile, so AFDIM did not dimension them.
[AFDIM] Skipped <n> object(s) whose geometry could not be read.AFDIM could not read the geometry of <n> objects, so it skipped them.
[AFDIM] Skipped <n> element(s) inside blocks/regions that could not be exploded.AFDIM could not break down <n> elements inside a block or region, so it skipped them. Your drawing is not changed.
[AFDIM] <n> continuous line(s) on a bend layer were read as bend lines, not as the outline.AFDIM read <n> continuous lines on a bend-line layer as bend lines, not as part of the profile.
[AFDIM] The selection is too large or its blocks/regions are nested too deeply. Stopped before dimensioning because the outline would be incomplete. Select less, or reduce the block nesting.The selection holds too many curves, or a block or region is nested too deeply. AFDIM stopped before dimensioning, so it wrote nothing. Select less, or explode some of the nesting.
[AFDIM] No CLOSED outline to dimension.There is no closed profile to dimension. See Troubleshooting.
[AFDIM] Could not build an outline from the selected lines.AFDIM could not build a profile from the selected curves. See Troubleshooting.
[AFDIM] Nothing selected. If the part is inside a viewport, double-click inside it and run AFDIM again.You are in a Layout, outside every viewport, and the selection is empty. See Selection in a Layout.
[AFDIM] QLEADER: <settings>AFDIM draws the callouts with QLEADER, because Draw callouts with: is set to QLEADER (follows the drawing’s own Leader Settings). The line shows where the QLEADER settings came from and which values AFDIM uses: leader type, attachment, arrow, text width and frame. This line is in English in every language.

AFDIM works in millimetres or in inches. The unit comes from Settings › General › Dimensioning › Drawing units:. The default is Automatic (from the current drawing). The other choices are Millimetres (mm) and Inches. The choice tells AFDIM how to read the numbers in your drawing. It does not change or rescale the drawing. It applies to every drawing, because AFDIM saves it in the settings file and not in the drawing. See Settings.

With Automatic, AFDIM reads the INSUNITS variable and the height of the dimension text. It reads the height on paper and after DIMSCALE or the annotation scale. When the unit is clear, AFDIM prints nothing. A drawing that is set up correctly in millimetres or in inches gets no unit message.

A millimetre drawing started from acad.dwt, whose INSUNITS still says inches, also gets no message when its dimension text is at least 1 unit high. AFDIM reads it as millimetres. If you work on both millimetre and inch drawings, keep Automatic.

In the cases below, AFDIM prints one message before it analyses the part. It prints each message once for each drawing in an AutoCAD session. It prints the message again only when the situation changes.

MessageWhen it appears and what to do
[AFDIM] The drawing has no declared unit; AFDIM is using inches from its dim text scale. Check Settings > Drawing units.INSUNITS says “unitless”, and the dimension text is less than 1 unit high, also after DIMSCALE or the annotation scale. AFDIM reads the drawing as inches. If the part is in inches, do nothing. If it is in millimetres, select Millimetres (mm).
[AFDIM] Drawing unit unclear: dim text <h> high, <h2> after the dim scale; AFDIM is using millimetres. If the part is drawn in inches, select Inches in Settings > Drawing units.INSUNITS says “unitless” or inches. The dimension text is less than 1 unit high on paper (<h>) and 1 unit or more after the scale (<h2>). A millimetre drawing started from a template with inch-sized text looks like this. AFDIM uses millimetres. If the part is in inches, select Inches. If it is in millimetres, select Millimetres (mm) to stop the message.
[AFDIM] AFDIM supports millimetres and inches; this other declared unit is being processed as millimetres. Select the correct unit in Settings > Drawing units.INSUNITS declares another unit, for example metres or feet. AFDIM processes the drawing as millimetres. AFDIM supports only millimetres and inches. If the part is drawn in one of them, select that unit.
[AFDIM] Settings force inches, but this drawing looks like it is drawn in millimetres. If that is wrong, select Automatic in Settings > Drawing units.You selected Inches, but the automatic reading of this drawing is millimetres. AFDIM uses inches, as you selected. If the selection is wrong for this drawing, select Automatic (from the current drawing).
[AFDIM] Settings force millimetres, but this drawing looks like it is drawn in inches. If that is wrong, select Automatic in Settings > Drawing units.You selected Millimetres (mm), but the automatic reading of this drawing is inches. AFDIM uses millimetres, as you selected. If the selection is wrong for this drawing, select Automatic (from the current drawing).

AFDIM prints <h> and <h2> in drawing units, with up to 3 decimal places.