How to use AutoCAD’s ‘FIND’ and ‘REPLACE’ command to correct text strings.
So – The situation is like this. You spent all day copying and pasting notes all over your drawing stating that the timber species can only be Cherry – and nothing else… Of course you get your drawings back from the Designer and they want to change it to Maple…Grrr
So you’re now faced with scouring your drawing to find all references to ‘Cherry’ and replacing them with ‘Maple’ – not only time consuming, but what if you miss a note?
Wait a minute, there’s got to be an easier way – right?
Of course there is – AutoCAD comes with a ‘Find and replace’ text tool, just like Word.
You can find it under:
Annotate tab > Text Panel
or
Edit Menu > Find
or type
‘FIND’ at the command prompt
The find and Replace Dialogue allows you to search your drawing for any text string, and replace it with another.
You can choose just part of the drawing or the whole file and you can chose whether to search inside Blocks and Xrefs. Click on the expansion arrow to see all the options.
By checking the ‘List Results’ box and hitting ‘Find’ you can see all the results listed.
Tip: Click on the ‘Zoom to highlighted result’ button, or double click on the highlighted text to be taken right to the result.
You can now have a look at the note in context before you hit ‘Replace’ – or you can just go Gung-Ho and hit ‘Replace all’ to do the lot.
Looking for more AutoCAD text tips? Check out how to strip unwanted formatting from Mtext.
Do you know a way to search for a string of text that spans multiple lines of an MTEXT entity? For example, if I have a multiline that looks like:
LINE1
LINE2
LINE3
The find will not find the string “LINE1 LINE2 LINE3”. I want to be able to find/replace all three lines at once :-/
Hi There,
I think that you will have to try a LISP routine or script to help with this.
A Google for ‘AutoCAD Advanced Find and Replace’ brought up this page:
http://www.cadstudio.cz/en/apps/srxtext/
Does that help?
Paul
Hey their text question again…. not just changing the name of the tree but i’m changing Maple_1-2 to Maple 1_20, Maple 1_30, Maple 1_45…. could you help a CAD Brother out?
Hi Hector,
This shouldn’t be an issue – what happened when you tried it?
Paul
Hey Tim,
Congratulations! My love to Mrs. P – Do I hear the patter of tiny feet? ;->
Yes this tip works with numbers as well, and it works with Dimension text – but not with the Dimension value… Which is a good thing!
Incidentally – if you have a problem with people editing the dimension value, you could use this tool from Autodesk Labs ‘Plugin of the month’ to find them out:
http://labs.autodesk.com/utilities/dimensionpatrol/
See how it works on Kean Walmsley’s Blog here:
http://through-the-interface.typepad.com/through_the_interface/2010/05/junes-plugin-of-the-month-dimension-patrol.html
Hi Paul,
Well I like this tip very handy!
Does it also work on numbers? ie somebody wrote in text on a section “125×45 hardwood” or similar and then you have to adjust the drawings and the section size changes.
Now I don’t do this because I think it is bad practise (thats what Dimensions are for), but I know some guys do, and when they revise their drawings(or we have to) it is a pain in the butt if they get missed, because all the sizes change, but the text remains the same!
By reading this reply you just know something went horribly wrong because of this very problem.
Luv to wife and Kids.
Tim
Ps I got married to Anne last week in Hawaii.