Find and replace strings in the names of selected files and folders in Finder
An AppleScript which does this job is the following:
.dontaioncontest_widgetbox { border: 2px solid #C0C0C0 !important; background-color: #F8F8F8 !important; text-align: center !important; padding: 5px 10px !important; max-width: 300px !important; line-height: 20px; font-size: 13px; } .dontaioncontest_widgetbox h3 { font-weight: bold !important; font-size: 14px !important; line-height: 17px !important; margin: 0px 0px 5px 0px !important; padding: 0px !important; border: 0px solid transparent !important; } .dontaioncontest_button { margin: 5px 0px 0px 0px !important; } .dontaioncontest_contestdata {top: 0px; left: 0px;}
To support my blog you can buy my app TunesLinker from App Store or use Paypal
An AppleScript which does this job is the following:
- --2012-04-05
- --http://www.organognosi.com
- set searchText to text returned of (display dialog "Find:" default answer "")
- set newText to text returned of (display dialog "Replace:" default answer "")
- tell application "Finder"
- set these_items to the selection
- repeat with this_item in these_items
- set fileName to name of this_item
- set newName to replaceText(fileName, searchText, newText) of me
- set name of this_item to newName
- end repeat
- end tell
- on replaceText(thisText, searchString, replacementString)
- set AppleScript's text item delimiters to the searchString
- set the itemList to every text item of thisText
- set AppleScript's text item delimiters to the replacementString
- set thisText to the itemList as string
- set AppleScript's text item delimiters to {""}
- return thisText
- end replaceText


