An introduction to Wildcard characters in AutoCAD

Wildcards are special characters that represent one or more characters in a string of characters. AutoCAD supports most of the popular wildcard characters. You can see a list of supported wildcard characters in AutoCAD on this Autodesk knowledge network page.

As an example, XYZ* would mean any string of characters where first three characters are XYZ and remaining characters can be anything represented by the * wildcard character. Similarly XYZ??ABC would mean a string of characters starting with XYZ followed by next two characters that can be anything represented with ?? wildcard then remaining three characters as ABC.

Although the wildcards can be used in a variety of situations but for the sake of simplicity, I will explain its application in two situations ie Find and Replace and Qselect. I will use this sample drawing for explaining this tip.

Wildcards in AutoCAD

Wildcards in Find and Replace:

You can find and replace text string using FIND command of AutoCAD. Let’s say we have a drawing in which lifts are mentioned as LIFT X where X indicates lift number. In order to change this name from LIFT X to ELEV X, we will use FIND command. Type FIND and press enter to start the command, Find and Replace window as shown in the image below will open.

wildcard characters in AutoCAD

Expand the window by clicking the down pointing arrow on the lower left side of the window and make sure use wildcards radio button is checked as shown in the image above.

You can select types of text to include in search from Text Types panel of Find and Replace window, in order to include all text types select all radio buttons as shown in the image above.

Now type LIFT # in Find what field and type ELEV in the Replace with the field. Now click in checkbox marked as List results under Replace with field and click on find. A list of all text entries with first four characters as LIFT followed by a blank space and a numeral value will be listed.

In the wildcard entry above # represents a numeric character. Select all the text elements that you want to change, you can select multiple entries by pressing and holding CTRL key.

Once you have selected all text entries to change click on Replace button. All text entries will now be changed to ELEV X, click on Done button to exit the Find and Replace window.

Using Wildcards with QSELECT:

To select text from drawing you can also use wildcard entries with QSELECT command.

Type QSELECT and press enter, now select Entire drawing in apply to drop down menu. Then select Text from object type drop down menu and select Contents from properties panel. Then select * Wildcard Match from operator drop down menu and type LIFT* in the value field as shown in the image below.

Once you have made all these settings click on OK to close the Quick Select window, all the text elements contacting first four characters as LIFT will be selected.

wildcard characters in AutoCAD

There are also other applications of wildcard entries in AutoCAD like using it in layer filters, layer search and searching for files in AutoCAD.

Do you have questions related to this tip? let us know in the comments below.

Learn AutoCAD from basics to a professional level with our self-paced online courses.

View Details
View Details

About the Author:

I am an embedded C software engineer and currently I am working as senior software engineer in one of the leading Software consulting company. I have working experience on different microcontrollers (stm32, LPC, PIC AVR and 8051), drivers (USB and virtual com-port), POS device (VeriFone) and payment gateway (global and first data) but I also love to explore many other Softwares including AutoCAD.

12 Comments

  1. Jims July 28, 2016 at 12:10 am - Reply

    sir, thanks for the lesson. I am having a query about find and replace. I have numbers like 111 or 110 , where i Have to change first digit no. i.e 1 to 2 . so the new no. 211 or 210. what is the wild card to use

    • Jaiprakash Pandey July 29, 2016 at 11:58 pm - Reply

      Using find and replace you simply can’t replace a string of text in that way, although you can find similar text using 1## wild card which indicates that 1 is followed by two numeric characters. Although you can use LISP routine for this.

  2. Anonymous February 23, 2016 at 4:25 pm - Reply

    Hi Jai,

    Usually I use find & replace. I am not used wildcard. anyway it’s very useful.

    Thanks & Regards,

    Pathroses

    • Jaiprakash Pandey February 23, 2016 at 8:20 pm - Reply

      I am glad you found it useful Pathroses

  3. Anonymous February 23, 2016 at 3:02 pm - Reply

    Normally I will use find & Replace. but I am not used with wild card. It is very usefull

    • Jaiprakash Pandey February 23, 2016 at 8:18 pm - Reply

      I am glad you found it useful

  4. Loi Diep. February 23, 2016 at 5:18 am - Reply

    Hi Jaiprakash I have been follow received AutoCAD tips from you and learning a lot from you.I have been use AutoCAD 2015 for a while.I would like to learn more 3D Modelling.How do I get more 3D exercises from you?I willing to pay to subscribe Please could you kindly tell me how to get that.I am looking forward to hear from you soon.Thank you very much.

  5. Anonymous February 22, 2016 at 7:39 pm - Reply

    Thnx for your good tips sir.

    • Jaiprakash Pandey February 22, 2016 at 10:01 pm - Reply

      Welcome

  6. Syed February 22, 2016 at 1:15 pm - Reply

    Thankyou Mr. Pandey for the good tip.

    • Jaiprakash Pandey February 22, 2016 at 4:08 pm - Reply

      Welcome Syed

Leave A Comment