 |
 |
Change Folder Label/Color Script
|
 |
|
 |
|
Fresh-Faced Recruit
Join Date: Jan 2001
Location: Santa Monica, CA, USA
Status:
Offline
|
|
I am trying to create a folder action that would change the label/color of a folder, any time a new file is added. Should be simple, but I have tried everything and i still can't do it. Any help would be appreciated. Thanks
|
|
|
| |
|
|
|
 |
|
 |
|
Dedicated MacNNer
Join Date: Nov 1999
Location: Georgetown, Demerara, Guyana
Status:
Offline
|
|
Hi bforest,
One potential snag of which you may already be aware is that Folder Actions (FA) scripts which process added/removed items currently do not work unless the target/source folder is *open*. [However, you could work around this limitation by using the freeware third-party extension, Folder Actions Plus, as mentioned in some earlier threads in this Forum (e.g., the Copying across network? thread, or the AppleScript Folder Actions thread).]
If your folder is indeed open, but the FA script still isn't working, then please let us know the exact commands that you're using to change the folder's label, and I or someone else will try to figure out what's going wrong.
[BTW, typically, inside the 'on adding folder items to ...' handler, you could say something like:-
Code:
on adding folder items to theFolderVar after receiving theItemsVar
-- [...]
tell application "Finder"
set (label index of theFolderVar) to n
end tell
-- [...]
end adding folder items to
where theFolderVar is the folder-variable that you've specified in the handler's "header", and n is an integer between 0 and 7 inclusive (0 = "None", and 7 = "Project 2" or whatever customised "bottommost" label you've set up).]
Regards,
--Paul
[This message has been edited by Paul Crawford (edited 01-19-2001).]
|
|
|
| |
|
|
|
 |
|
 |
|
RGS
|
|
I need some clarification...
When you drop a file into the folder with the attached folder action, you want that folder's (with the attached folder action) label to change? Random or specific label?
|
|
|
| |
|
|
|
 |
|
 |
|
Fresh-Faced Recruit
Join Date: Jan 2001
Location: Santa Monica, CA, USA
Status:
Offline
|
|
RGS,
That is correct, I want to have a specific folder with a folder action attached to change to a specific color when an item is added. I can now do it, but only when the target folder is ope as stated above...haven't tried those 3rd part solutions. Thanks for the help
|
|
|
| |
|
|
|
 |
 |
|
 |
|
|
|
|
|

|
|
 |
Forum Rules
|
 |
 |
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
 |
 |
 |
 |
|
 |
|