Register FAQ / Rules Forum Spy Search Today's Posts Mark Forums Read
Go Back   MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Reply
 
Thread Tools Search this Thread Display Modes
Old Mar 6, 2013, 03:10 PM   #1
andrewakessler
macrumors newbie
 
Join Date: Mar 2013
Applescript help: color labels of files upon download

Hello, I'm trying to figure out how I can create an applescript that changes the color of a movie file upon download to a series of nested folders, and then removes the color label upon opening.

In simple terms:

Upon download, movie file is automatically placed in:

TV folder
Show Title folder
Season folder

Applescript notices new movie file in folder / subfolder

set color label of movie file to orange

when movie file is opened, script removes color label.

Is this even possible?

Thanks for the help.
andrewakessler is offline   0 Reply With Quote
Old Mar 6, 2013, 05:41 PM   #2
andrewakessler
Thread Starter
macrumors newbie
 
Join Date: Mar 2013
How about a script for changing a color label when a file has been opened? Is this possible?
andrewakessler is offline   0 Reply With Quote
Old Mar 7, 2013, 07:41 AM   #3
kryten2
macrumors 6502a
 
Join Date: Mar 2012
Location: Belgium
A folder action created in Applescript or Automator would do the first part.

Code:
on adding folder items to this_folder after receiving these_items
	-- insert actions here
	-- Put logic into script to move files to desired location and attach color labels to files based on name extension or something else.
	-- insert actions here
end adding folder items to

For the other part perhaps you can use the value of the kMDItemLastUsedDate attribute of the mdls command and work with that(see attached tumbnail). For more information on the mdls command --> In Terminal :

Code:
man mdls
Info : http://hints.macworld.com/article.ph...70408193708936
Attached Thumbnails
Click image for larger version

Name:	Picture 14.png
Views:	17
Size:	72.1 KB
ID:	401189  
__________________
Space Corps Directive 34124
kryten2 is offline   0 Reply With Quote
Old Aug 30, 2013, 01:20 PM   #4
see.solve.
macrumors newbie
 
Join Date: Oct 2012
Hazel.
see.solve. is offline   0 Reply With Quote

Reply
MacRumors Forums > Apple Systems and Services > Programming > Mac Programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
thread Thread Starter Forum Replies Last Post
How to assign color labels to files? red321red321 OS X Mavericks (10.9) 60 Jun 27, 2014 12:09 PM
iPhone: Color mail labels iOS 7 Shapelessbb Jailbreaks and iOS Hacks 0 Jan 28, 2014 02:55 AM
Changing color labels of enclosed items ^Tripper^ Mac Basics and Help 7 Mar 13, 2013 12:28 PM
iPhone: Color Mail Labels BoyzOf4d Jailbreaks and iOS Hacks 0 Feb 26, 2013 10:31 PM
Color Labels and SMB Shares HughMad Mac OS X 10.7 Lion 0 Jan 8, 2013 05:37 PM

Forum Jump

All times are GMT -5. The time now is 10:37 AM.

Mac Rumors | Mac | iPhone | iPhone Game Reviews | iPhone Apps

Mobile Version | Fixed | Fluid | Fluid HD
Copyright 2002-2013, MacRumors.com, LLC