Trying to make a file alias, but I'm stuck!

I've come up with 3 ways to do the same thing, and none of them work..
I want a droplet where I can drop a file (this case, a photo) and then an alias is created in another specified folder on the desktop. I have a hundreds of photos to go thru and i want to have a shortcut to the ones that are approved, so I can go back later and photoshop them. I don't want to double up on the photos and I want to keep the structure they're in now, so I don't want to move them.
Where am I going wrong with any one of these...??
*Script 1*
on open draggeditems
tell application "Finder"
set draggeditem to theFile
make new alias of file in folder "Approved" of folder "Desktop" of folder "kit" of folder "Users" of startup disk to theFile
end tell
end open
Returns: The variable theFile is not defined.
*Script 2*
on open draggeditems
tell application "Finder"
set draggeditems to input
set alias of the input to make new alias file at folder "Approved" of folder "Desktop" of folder "kit" of folder "Users" of startup disk to input
end tell
end open
Returns: The variable input is not defined.
*Script 3*
on open draggeditems
tell application "Finder"
set sourcefiles to thisFile(draggeditems)
repeat with thisFile in sourcefiles
tell application "Finder" to reveal item thisFile
set thisFile to thisFile as alias
set alias of file in folder "Approved" of folder "Desktop" of folder "kit" of folder "Users" of startup disk to thisFile
end repeat
end tell
end open
Returns: Can't continue thisFile.
I realise there's a trend showing here, but I can't seem to break it..

The errors are fairly straightforward when you realize what's going on.
In scenario 1:
on open draggeditems
so 'draggeditems' is a list of the files that were passed to your script.
Two lines later you say:
set draggeditem to theFile
So now you're trying to set 'draggeditem' to 'theFile', but nowhere in your script is theFile defined. Hence the error.
I'm assuming you want to extract each file from the list of draggeditems, in which case you want something like:
<pre class=command>repeat with theFile in draggeditems</pre>
so now 'theFile' contains a reference to each file in turn. From there you can make an alias to it:
<pre class=command>make new alias to file theFile at folder "Approved" of (path to Desktop)</pre>
So, in all your script should look more like:
on open draggedItems
 repeat with theFile in draggedItems
  tell application "Finder"
   make new alias to file theFile at folder "Approved" of (path to Desktop)
  end tell
 end repeat
end open</pre>

Similar Messages

  • I am trying to make a iphoto book but every time i click on a single photo or folder it opens up a new book. How can I avoid this? This is iphoto 10.

    I am trying to make a iphoto book but every time i click on an individual photo (or folder) it opens up a new book. How can i avoid this?

    Export the slideshow out of iPhoto as a QT movie file via the Export button in the lower toolbar.  Select Size = Medium or Large.
    Open iDVD, select a theme and drag the exported QT movie file into the open iDVD window being careful to avoid any drop zones.
    Follow this workflow to help assure the best quality video DVD:
    Once you have the project as you want it save it as a disk image via the File ➙ Save as Disk Image  menu option. This will separate the encoding process from the burn process. 
    To check the encoding mount the disk image, launch DVD Player and play it.  If it plays OK with DVD Player the encoding is good.
    Then burn to disk with Disk Utility or Toast at the slowest speed available (2x-4x) to assure the best burn quality.  Always use top quality media:  Verbatim, Maxell or Taiyo Yuden DVD-R are the most recommended in these forums.
    If iDVD was not preinstalled on your Mac you'll have to obtain it by purchasing a copy of the iLife 09 disk from a 3rd party retailer like Amazon.com: ilife 09: Software or eBay.com.  Why, because iDVD (and iWeb) was discontinued by Apple over a year ago. 
    Why iLife 09 instead of 11?
    If you have to purchase an iLife disc in order to obtain the iDVD application remember that the iLife 11 disc only provides  themes from iDVD 5-7.  The Software Update no longer installs the earlier themes when starting from the iLIfe 11 disk nor do any of the iDVD 7 updaters available from the Apple Downloads website contain them. 
    Currently the only sure fire way to get all themes is to start with the iLife 09 disc:
    This shows the iDVD contents in the iLife 09 disc via Pacifist:
    You then can upgrade from iDVD 7.0.3 to iDVD 7.1.2 via the updaters at the Apple Downloads webpage.
    NOTE:  If you're running iPhoto 9.5 the export options will be different.
    OT

  • The iCloud was never verified therefore never backing up anything on my iphone 4s because it was the wrong email and now I'm trying to make a new one but it says if I delete the account it will remove it's data from my phone. Will I lose everything?

    The iCloud was never verified therefore never backing up anything on my iphone 4s because it was the wrong email and now I'm trying to make a new one but it says if I delete the account it will remove it's data from my phone. So if I put delete account will I lose everything on my Iphone?

    This was EXACTLY what I needed about the purchases I made from my device. However, is there a way to re-download other ones you've made from a computer? Because I realized some of them were not just purchased from my device.
    This is a picture of what it looks like now:
    http://tinypic.com/r/107quxu/7
    As you can see, the stuff circled in red doesn't give me an option to download from Cloud Beta because it already says "downloaded".
    any way to get around that?

  • I tried to encrypt using file vault but it froze slowing my macbook pro, how can i get things moving or stop the encryption

    i tried to encrypt using file vault but it froze slowing my macbook pro, how can i get things moving or stop the encryption

    Back up all data before proceeding. There are ways to back up a computer that isn't fully functional. Ask if you need guidance.
    Start up in Recovery mode. When the OS X Utilities screen appears, select Disk Utility.
    In the Disk Utility window, select the icon of the startup volume from the list on the left. It will be nested below another disk icon, usually with the same name. Click the Unlock button in the toolbar. When prompted, enter the login password of a user authorized to unlock the volume, or the alternate decryption key that was generated when you activated FileVault.
    Then, from the menu bar, select
              File ▹ Turn Off Encryption
    Enter the password again.
    You can then restart as usual, if the system is working. Decryption will be completed in the background. It may take several hours, and during that time performance will be reduced.
    If you can't turn off encryption in Disk Utility because the menu item is grayed out, you'll have to erase the volume and then restore the data from a backup. Select the Erase tab, and then select
              Mac OS Extended (Journaled)
    from the Format menu.
    You can then quit to be returned to the main Recovery screen. Follow these instructions if you back up with Time Machine. If you use other backup software, follow its developer's instructions.
    Don't erase the volume unless you have at least two complete, independent backups. One is not enough to be safe.

  • Trying to make a bootable disc but i keep getting this message as a failure notice. "Could not find any scan information. The source image needs to be imagescanned before it can be restored.", what can I do?

    Trying to make a bootable disc but i keep getting this message as a failure notice. "Could not find any scan information. The source image needs to be imagescanned before it can be restored.", what can I do? Any help at all would be appreciated.

    Have you tried scanning the source image? Disk Utility > Images menu > Scan Image for Restore…

  • I'm trying to make a holiday card, but can't figure out how to get photos into the card.

    I'm trying to make a holiday card, but can't figure out how to get photos into the card.

    Selectto( s) and create the card - if you want to add more photos ot it drag then to the card project in the source pane on the left
    LN

  • Im trying to get ride of Alias but it keep making copy Now my trash is so big....How long it will take to empty the trash

    Im trying to get ride of Alias but it keep making copy Now my trash is so big....How long it will take to empty the trash

    That's not how it works. Once a device (including a computer) is associated with an Apple ID it cannot be switched for 90 days. See this Apple KB article for more information: http://support.apple.com/kb/HT1420.

  • TS3694 i was trying to update my iphone 5 but it got stuck on itune screen. whenever i try to restore it says error (1669) what can i do. please help

    i was trying to update my iphone 5 but it got stuck on itune screen. whenever i try to restore it says error (1669) what can i do. please help

    Try  these troubleshooting steps.
    If that Article did not resolve it... then perhaps a Visit to an Apple Store or AASP (Authorized Apple Service Provider) is required..
    Be sure to make an appointment first...
    Note:
    That error message may be indicative of the Device being Hacked / jailbroken.... If this is the case then you are on your own.
    Unauthorized modification of iOS...
    http://support.apple.com/kb/HT3743

  • My mini ipad is stuck at apple logo its ios 7.0.4 ive tried to restore it 2 times but its kept stuck what should i do now ? I became so afraid

    My mini ipad is stuck at apple logo its ios 7.0.4 ive tried to restore it 2 times but its kept stuck what should i do now ? I became so afraid
    Ive hold the two buttoms and it went to recovery mood and then i did restore but its again stuck

    iPad: Basic troubleshooting
    http://support.apple.com/kb/TS3274http://support.apple.com/kb/TS3274
    Update and restore alert messages on iPhone, iPad, and iPod touch
    http://www.buybuyla.com/tech/view/012953a0d412000e.shtmlhttp://www.buybuyla.com/tech/view/012953a0d412000e.shtml
    iOS: Resolving update and restore alert messages
    http://support.apple.com/kb/TS1275
    iPad: Unable to update or restore
    http://support.apple.com/kb/ht4097
    iTunes: Specific update-and-restore error messages and advanced troubleshooting
    http://support.apple.com/kb/TS3694http://support.apple.com/kb/TS3694
    If you can't update or restore your iOS device
    http://support.apple.com/kb/ht1808
     Cheers, Tom

  • I tried to make a second library, but my first one was deleted so I did it again but now I have doubles of every song. How do I restore my itunes back to the way it was before I tried to make a 2nd library?

    Like I said I tryed to make another library, I did what Itunes told me to do but it only erased the library I had and made a new one. So I did it again but I now have duplicates of every song. How do I get my it back to the way it was, before I tried to make a second library?

    C:\Users\Cheye\Music\iTunes should be the original library. You should be able to connect to it as follows.
    Close iTunes, wait a few seconds, click the icon that starts iTunes and immediately press and hold down the shift key. Keep holding until asked to choose or create a library. Click choose and browse to the file C:\Users\Cheye\Music\iTunes\iTunes Library.itl.
    Depending upon exactly what you did this has either restored your library, or done absolutely nothing at all. That was the reason for asking you to check using the script.
    Assuming you still have a library full of dupes there are a number of ways to go. I've written a script called DeDuper which can help remove unwanted duplicates which I discuss in some detail in this  thread. While it should work it will be ideal if it discards the copies that are outside the media folder C:\Users\Cheye\Music\iTunes\iTunes\iTunes Media. I've a feeling it will do exactly that, but it depends in part on exactly you got into this mess. It would be worth doing a few sample runs of just a few sets of duplicate files first.
    tt2

  • Trying to make a file viewer

    I am trying to make a program which allows the user to select a file and display it on the screen in LabVIEW 6.1. My problem is that the Picture control seems to hold the previous as well as the current pictures. I am new to using image applications in LabVIEW and cannot find a way to erase the image (if I send an empty image it just goes into the rotation).
    Can anyone offer some suggestions?

    I'm not sure if this is what you mean, but attached is a small example program demonstrating the effect of the "Erase First" Property.
    If you run the vi with Erase true, toggling the top switch between runs results in either one or two circles being drawn. If you set Erase to false, the drawing will always show two circles, regardless of the position of the top switch, or more accurately, any new drawing is simply layered on top of what's already there.
    Mike...
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps
    Attachments:
    picture_example.vi ‏34 KB

  • I was trying to make a apple id but typed in the wrong email address

    So i was trying to make a new apple id for my ipod touch because i got a gift card but i think i typed in the wrong email address because i have not gotten the comformation email yet. While your signing up it asks you if you want to add a gift card so i added my gift card but now if i cant get into my apple id then i just lost $15. please help

    Contact iTunes:
    Apple - Support - iTunes - Contact Us

  • HT2731 m trying to make my apple id but its saying again and again that your payment method is declined now what should i do i have putted visa as payment method

    m trying to use my apple id but the system is not accepting my payment method as i choose visa now what shoul i do ??

    What sort of visa card is it, debit or credit ? If it's a debit card then I don't think that they are still accepted as a valid payment method - they are not listed on this page and there have been a number of posts recently about them being declined
    If it's a credit card then is it registered to exactly the same name and address (including format and spacing etc) that you have on your iTunes account, it was issued by a bank in your country and you are currently in that country ? If it is then you could check with the card issuer to see if it's them that are declining it, and if not then try contacting iTunes support and see if they know why it's being declined : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then Account Management

  • Trying to make changes in Terminal but can't get past the password request

    I am trying to run Piano Wizard from a managed accout but I get this: Data.pwf missing
    I found these FIX instructions on their web site but I can't get it to work....
    METHOD1: If you know the password of the owner account of the machine. Please follow only these instructions. The changes outlined below will modify only the Piano Wizard files.
    Terminal: (These instructions are for a standard install with the game installed to Applications) refers to the user account that owns the machine – you will have to know the name of this admin user (i.e. bob)
    1. Launch Terminal (Applications->Utilities->Terminal)
    2. "cd /Applications"
    3. "su "
    4. enter the password and hit enter
    5. "chmod -R 755 Piano Wizard.app/"
    We are now done - close Terminal by hit COMMAND-Q (Apple-Q) That's it - launch Piano Wizard
    When I launch Terminal I get - "computer name":~"admin name"$, I follow steps 1-3 not problem...
    I get to step #4, put in my password then I get this "su: Sorry"
    Please help, I only know of one password...is there another one somewhere?
    MacBook   Mac OS X (10.4.8)  

    Run the following command:
    chmod -R 755 Piano\ Wizard.app
    Spaces and other special characters need to be escaped when entering commands into the Terminal; this can be done by putting a backslash in front of them, or enclosing some or all of the string in quote marks:
    chmod -R 755 'Piano Wizard.app'
    (18951)

  • How can i transfer mp3 files to itunes and then onto my phone. I tried clicking the add file button but it wont do anything . Please Help

    I have been trying to add some mp3 files to my phone but i cant even get them into itunes. I tried clicking Control O which brings up the page where it shows a screen that tells you to pick your audio files but whenever i click them the songs will not download to itunes. The songs that i already have on itunes wont go to my phone even if i try and sync them . Please help and Thank You in advance.

    For how to sync:
    iTunes: Syncing media content to iOS devices and iPod       
    To import media into your iTunes library on the computer go to iTunes>Help>iTunes Help>Add items to iTunes and follow the instructions

Maybe you are looking for

  • How to find the Paid date of a Sales A/R Invoice?

    Hi Guys, I have extracted the Sales Invoice Detail for my ETL Product,I extracted mosltly all datas related to Invoice.Finally <b>I can't find the exact paid date for the Sales A/RInvoice.</b>Could anybody tell me ,How the Paid date for that invoice

  • How to change from SLIM to KDM?

    Hello, I'm using the MATE desktop, OpenBox as window manager and SLIM for login. I'm starting to feel tired of not being able to change between various desktops without closing the main one, I mean, with OpenSUSE Ctrl+Alt+F1 to F6 are terminal ttys (

  • Loading class from an external .swf file

    Hi, My flash application has lots of resources which will change all the time. In order to keep the the user from having to download my main .swf file over and over again, and in order to keep the main file's size low, I would like to put the resourc

  • Can't Share SQL Server 2000 in Windows 7 Pro

    I had installed SQL Server 2000 in my Windows 7 Professional and use in it in this PC. But Can't Use in my network Group Windows 7 Professional and Windows Xp, Can I Solve This Issue?

  • I cant convert PowerPoint to PDF it keeps showing no text etc why?

    I am unable to convert PowerPoint to a PDF. This should be a simple selection of Save As Type and select PDF. But when it converts it then show the design only but no content in the document. I have not had issues before this past week as I recall. C