Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'script to add size column' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
script to add size column
Authored by: tedw on Jan 17, '10 12:25:44AM
Just to help people out, here's a script that adds the size column to Finder searches.
tell application "Finder" to quit
tell application "System Events"
	set theFinderPrefsFile to POSIX path of (file "com.apple.finder.plist" of preferences folder of user domain)
	set theFinderPlist to property list file theFinderPrefsFile
	tell theFinderPlist
		tell property list item "SearchViewSettings"
			tell property list item "ListViewSettings"
				tell property list item "columns"
					tell property list item "size"
						set value of property list item "visible" to true
					end tell
				end tell
			end tell
		end tell
	end tell
end tell
delay 3 -- just to make sure the plist file is written to disk
tell application "Finder" to launch
To remove the size search, set visible to false instead of true in the above. My concern with this is that it would force the system to calculate file sizes at search time, which might slow down searches some and increase processor activity. Has anyone noticed that kind of effect? P.s - to use this, open the Applescript Editor in the Utilities folder, copy this script into it, and click Run.
Edited on Jan 17, '10 12:26:57AM by tedw


[ Reply to This | # ]