• 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
Script for moving files.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Script for moving files.


  • Subject: Script for moving files.
  • From: Manuel <email@hidden>
  • Date: Thu, 20 Jun 2013 20:58:49 +0200

Hello scripters. 

I´m trying a folder action for moving files based in the extension and name, but I can´t. 
If the code looks for just extensions, it works, but when I want also the name, the files don´t move. 

This is the code:
 
property videoExtensiones : {"mkv", "mp4"}
property videoNombres : {"Hannibal", "Continuum", "Elementary"}

on adding folder items to this_folder after receiving downloaded_items
tell application "Finder"
repeat with i from 1 to number of items in downloaded_items
set archivoDescargado to item i of downloaded_items
if name extension of archivoDescargado is in videoExtensiones and name of archivoDescargado starts with videoNombres then
move archivoDescargado to folder "TV SERIES" of disk "WINOSX"
end if
end repeat
end tell
end adding folder items to


Thanks in advance for your help. 
Regards, 
Manuel.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: Script for moving files.
      • From: Axel Luttgens <email@hidden>
    • Re: Script for moving files.
      • From: Luther Fuller <email@hidden>
  • Prev by Date: Re: openPanel using Automator Runner
  • Next by Date: Re: Script for moving files.
  • Previous by thread: use applescript to import contacts
  • Next by thread: Re: Script for moving files.
  • Index(es):
    • Date
    • Thread