How to Create a New Command on Autocad

Ever used the same AutoCAD command over and over again? Wish there was an easier way? There is! Follow these simple steps to create a button on the toolbar that does most of the typing for you!

Type “cui” in the command line and press “Enter.”

This will bring up the “Customize User Interface” dialog box.

This area lets you create custom commands.

  • This article will show you how to create a command that copies an object in place.

Create a new command.

Right click the command list and select Create a New Command.

The properties for a new command will expand.

Name your command.

Rename your command to accurately describe what it will do.

Stay consistent with your naming conventions so you always know what each command is for.

Edit the macro.

For our sample “copy in place” command, we have specific macro.

  • “^C^C_copy 0,0 0,0”
  • “^C” is cancel or the equivalent of pressing the Esc key. Always start your command with two ^C in front to exit any commands you may be in.
  • “_copy ” initiates the copy command
  • A space will do the same as pressing spacebar in the command line.
  • The copy command then asks for a base point, and our macro inputs 0,0.
  • To copy in place we then specify 0,0 for the point we copy to.

Add an icon.

Give your New Command an icon if you wish.

You can do this by clicking the dots next to “Images” and selecting an icon.

Drag the command to a toolbar.

Put it on existing toolbar or create your own.

Tips

  • This article was written using AutoCAD 2009. This may or may not work in earlier versions of CAD.
  • The Custom User Interface (CUI) was added in AutoCAD 2006. Therefore, this tip WILL NOT WORK in AutoCAD versions 2005 or older.

Warnings

  • You may become so addicted to creating your own commands and toolbars, that you don’t get any work done!

Leave a Comment