| By Charlie Arehart | Article Rating: |
|
| September 16, 2003 12:00 AM EDT | Reads: |
6,533 |
Ever had to find all the references to a given string among all the files in your application? And how about in all the files in any of several subdirectories, perhaps in your web root? Even more challenging, have you wanted to change occurrences of a string in such a large number of files? Studio's Extended Find and Extended Replace commands are just the ticket.
Available in Studio from the Search command on the menu bar, or the shortcuts Ctrl-Shift-F and Ctrl-Shift-R, the commands are a real timesaver.
Among the many features of the commands are that you can:
- run either command against the current document, all open documents, any folders (and their subfolders, optionally), or a project — which means you can indeed search against RDS file directories, by setting them up as a project
- selectively save and reuse entries (Click the arrow button next to the Find what box)
- restrict execution to files with specified extensions
- enforce case-sensitive searches (via a checkbox)
- use regular expressions to search (via a checkbox)
- choose to search page content only, excluding the tags themselves (via a checkbox)
- choose to backup files before making replacements at the folder or project level (via a checkbox)
A Results pane displays a list of locations where the matched string was found/replaced. You can double-click on a match in the list to highlight it in the document. Right-click in the Results pane to clear the pane or close it.
Keep the following in mind:
- the Extended Replace command skips read-only files
- you may find it helpful to use the Alt-W shortcut to move to the "Find Where" portion of the dialogue, and the Alt-P shortcut to move from the "find what" prompt to the "replace with" prompt when doing a replace
- as with most Find dialogues, if you highlight text in the editor before calling up the command, that text will be filled in automatically for the "find what" prompt see chapter 12 in Using CF Studio
See Studio's Help tab (or the Help command on the command menu) for more information — all the Allaire documentation is there. It's in Chapter 12 in 4.5 and Chapter 6 in 4.01.
Published September 16, 2003 Reads 6,533
Copyright © 2003 SYS-CON Media, Inc. — All Rights Reserved.
Syndicated stories and blog feeds, all rights reserved by the author.
More Stories By Charlie Arehart
A veteran ColdFusion developer since 1997, Charlie Arehart is a long-time contributor to the community and a recognized Adobe Community Expert. He's a certified Advanced CF Developer and Instructor for CF 4/5/6/7 and served as tech editor of CFDJ until 2003. Now an independent contractor (carehart.org) living in Alpharetta, GA, Charlie provides high-level troubleshooting/tuning assistance and training/mentoring for CF teams. He helps run the Online ColdFusion Meetup (coldfusionmeetup.com, an online CF user group), is a contributor to the CF8 WACK books by Ben Forta, and is frequently invited to speak at developer conferences and user groups worldwide.
- Validating Input with Regular Expressions
- Getting Focus()ed and a Quick JavaScript Lesson
- Setting Up Your Development Server with ColdFusion 5, MX, and BlueDragon
- Toward Better Error Handling
- Monitoring Your ColdFusion Environment With the Free Log Parser Toolkit
- New Possibilities for Session/Client Variable Handling in CFMX
- Testing Existence in Arrays
- Making the Case for CFML on J2EE
- Exploring Amazon Web Services with ColdFusion MX
- Getting Focused - and a Quick JavaScript Lesson
- CFML on J2EE: Easy as 1-2-3
- Getting into HomeSite+

























