• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Timed watched folders
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Timed watched folders


  • Subject: Re: Timed watched folders
  • From: Rob Jorgensen <email@hidden>
  • Date: Fri, 16 Jan 2004 10:25:28 -0500

At 9:48 AM -0500 1/16/04, Chad Lindsey wrote:
Matthew,
It does work on the desktop machine, and usually on the server.
What I really want is it to look at the first two characters to see if it
contains "DT", if it does it will also check to see if it contains "_cdot"
or "_spot", if it contains DT and -cdot, it moves to a certain folder, if it
contains DT and spot, it moves to a specific folder, and if it contains DT
and no _cdot or _spot it moves to a specific folder. I tried, but not sure
if I am getting it correct.
This is grabbing files from a universal incoming folder, just grabbing files
that are named with DT in the first two spots.

Maybe this will work:

on adding folder items to this_folder after receiving added_items
repeat with aFile in added_items
repeat
set size_check1 to size of (info for aFile)
do shell script "sleep 10"
set size_check2 to size of (info for aFile)
if size_check1 is equal to size_check2 then exit repeat
end repeat

tell application "Finder"
try
set name_ to name of aFile
if name_ begins with "DT" then
if name_ contains "_cdot" then
tell application "Finder"
try
copy aFile to folder "ServerFolderA"
on error err
display dialog err
end try
end tell
move aFile to folder "MacHD:Copied" with replacing
else if name_ contains "_spot" then
tell application "Finder"
try
copy aFile to folder "ServerFolderB"
on error err
display dialog err
end try
end tell
move aFile to folder "MacHD:Copied" with replacing
else
tell application "Finder"
try
copy aFile to folder "ServerFolderC"
on error err
display dialog err
end try
end tell
move aFile to folder "MacHD:Copied:" with replacing
end if
end if
end try
end tell
end repeat
end adding folder items to

-- Rob
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: applescript-users digest, Vol 3 #2339 - 14 msgs (From: Chad Lindsey <email@hidden>)

  • Prev by Date: Re: Looking for script that replaces last chars and replace it by .jpg
  • Next by Date: Re: Connect to SMB server
  • Previous by thread: Re: applescript-users digest, Vol 3 #2339 - 14 msgs
  • Next by thread: Re: Timed watched folders
  • Index(es):
    • Date
    • Thread