Using Find and Replace In TextEdit and Other Apps

Find and replace is useful tool for writers, editors and anyone who works with large word processing documents. You can use a variety of special find features in TextEdit to refine your searches. If you know the right techniques, you can swap words and search for patterns. In Pages searching isn't as powerful, but Microsoft Word has even more advanced features.
Video Transcript / Captions
Closed captioning for this video is available on YouTube: Using Find and Replace In TextEdit and Other Apps.

Hi, this is Gary with On today's episode let's look at using Find and Replace in TextEdit and other apps.

Find and Replace is a tool I use all the time and I take it for granted. But a lot of people don't know about it or don't use it. You can find it in most word processing apps. I'm going to demonstrate here first in TextEdit. I've loaded in the Project Gutenberg version of The Call of the Wild. So a very large document here and say I wanted to universally replace something throughout.

Well, first I'll start with Find and then I'll look at Find and Replace and then I'll look at Find and Replace All to do it all in one shot.

So to find something I would go first to Edit and then Find. Now it is going to be in a slightly different place in different apps. Sometimes there is an entire Find or Search menu all by itself. But here it is in Edit. I've got Find and some other similar commands. Let me just start with Find here because I can get to everything through there. This will actually bring up a toolbar at the top where I can type some text and then I will get some results.

So let me type in the word dog. As you can imagine in this book it appears a lot. You can see actually right here it says 198 times. Now I can use these arrows to go through them. So I can go to the next one and keep going and look at all the instances of the word dog, or at least those three letters together dog, and see them. So there it even finds dogs because I'm searching for those three so it's going to find them inside of that word.

Now you don't just have to use these arrows. You can actually use keyboards shortcuts. Look under Find and you can see Find Next and Find Previous, Command G and Shift Command G, will allow you to do this very quickly. So I'm going to do Command G through the document and you can see I can just jump around looking for maybe the one instance of this word that I wanted to change or get to so I can edit something else nearby. Shift Command G will go backwards through the document. So using those shortcuts you can jump around and look for what you need.

Say if you are searching for something and there is only seven of them and you know that there is something you want to change near one of those you can just do a Command F, type the word, hit return to find the first one and Command G to go to the second one, third one, fourth one, etc.

Alright so now suppose I want to change all of these. Well, what I can do here is I can check off this Replace box here. Now I get a second field and I can replace it with something. So let's replace dog with cat. Now I can hit two buttons here; Replace or replace All. If I hit Replace you see it changed that one and automatically jumps to the next one. I can continue to use Replace and go through them all. This actually will help because if I wanted to skip one, say skip this one, I can hit the next arrow there and then just replace the next one. So if you want to change some but not all instances of a set of letters you can do it using these two buttons here.

Likewise you could just go and say All and it will replace all of them that are present in the entire document.

Now you saw how it would find the letters d, o, g inside of another word and would find those and also replace those. So I could do something a little more precise here. If I search for cat see 33 things come up and I don't remember there being any cats in the book. But you can see right here it just found it in the word scattering, scatter, and other words.

So I can click here on the Options and you can see I get lots of different options. Like Ignore Case, Wrap Around which means that if you are at the end of the document it will wrap around and continue to search at the beginning of the document. I can look for words that Contains, Starts With, Full Word.

So let's try that. Full Word here for cat and you can see there's two of them. So you see one and there's two. So there are actually two instances here where the word cat appears. Sure enough as I'm doing something here where I'm looking for the entire word I want to look for cats as well. None of those. So there is just two of these.

Now the technique I use say if I wanted to replace all of the dogs with cats I can do that and it would leave these two instances of cat in place. So what I probably want to do is first search for cat, say if I wanted to change cats to dogs, I could search for cat. Replace cat with something like that; cat with four asterisks after it and Replace All.

So now you can see I've changed it to be this. So now if I were to go and change all the dogs to cat I can Replace All and if I search for cat you can see I can find those two instances now and I can change those both to dog. So now I've got the cats and the dogs switched.

Now TextEdit actually has some very powerful search functions. I can go into the Options here and I can Insert Pattern. So, for instance, lets say I want to search for all the words that start with the letter b and end with k. So I'm going to type the letter b here and then I'm going to Insert Pattern and I'm going to, first let's insert any character and then k. Now it will find any group of letters that start with b and end with k. B and K. So I don't want that. I want actually to have a word that starts with b and ends with k.

So I can go to Full Word here and now, sure enough, there I go and I've got instances of Buck, there's back, and any other word that would fit that. I've got a whole bunch of different things I can insert here. Word Breaks, White Space, single Digits. I can even just search for an email address or URL. So, for instance, let's do a URL here and erase this part of it and you'll see that you can find several URLs inside of this text. I'll turn off Full Word here and now it should come up. Sure enough there is some URLs there in the header information for this. So there's all sorts of different things that I can search for. Let's see if there are any email addresses in here. Indeed there are two.

So you've got a lot of power here if you get to know these. It is not as complex as using what's called Grep by programmers who can search using other apps for very complex strings but you can do some very basic things in here if you play around with these and figure out what they can do. You can also insert special characters like tabs and line breaks and things like that. So you can find say words that are at the end of a line by looking for the word and then ending with line break or paragraph break.

Now looking in Pages you've got a similar thing here. Find actually will bring up a little moveable window and you can search for things. It will show you the number found and you can page through them. You can switch over to replace and it is just a different arrangement but it is basically the same thing. Replace All, Replace and Find, or just Replace and stay in that current location. But you don't have as many options. You can do whole Words or Match Case or not but you can't do all the special search functions in Pages.

In Microsoft Word you've go the basic Find command which brings up a very simple way to find. Then you can also do Find, Replace. But you also have the Advanced Find and Replace. Here you can do things like actually have Wildcards, if you check off Use wildcards. Put asterisks there. You've got lots of different options. You've also got the ability to Find with Formatting and Styles and things like that. So you can words that are particular styles and all sorts of things. It is a pretty deep comprehensive Find and Replace as you would expect to find in Word.

Find and Replace isn't restricted to just word processors. For instance here in Keynote we find that it has exactly the same functionality as it does in Pages. So you can Find and Replace some of the basic stuff. But if you have a big presentation and you need to replace something throughout it or just search through all those items to find something. You can do the same thing here as you can in Pages.

Comments: 3 Responses to “Using Find and Replace In TextEdit and Other Apps”

    3 years ago

    Wow. I had no idea you could do all that stuff in TextEdit. Wish I had known that years ago. Too bad that Pages is so weak.

    Donna Gordon
    3 years ago

    Thanks for that information. TextEdit something I use occasionally and will apply this information. I usually use Pages. Wish it had more capability in this area.

    3 years ago

    Very helpful. Thanks. It’s clarified the ‘wild card’ option in Word. I tend to use Nisus Writer Pro for word processing, and this video will have set me up to get to grips with the finer points of Find and Find & Replace there too.

Comments Closed.