Copy "Artist - Song name" to the clipboard

The aim is to assign a shortcut for copying the artist and name of currently playing or selected song from iTunes to the clipboard.
How it can be done?

I usually recommend not manipulating the clipboard via AppleScript - not because it can't be done (it can), but because there are usually better options.
In any case, since I don't know what you're ultimately trying to do...
tell application "iTunes"
          if player state is playing then
                    set TA to artist of (get current track)
                    set TN to name of (get current track)
  set the clipboard to TA & " - " & TN
          end if
end tell
The issue is assigning this to a key shortcut, which AppleScript can't do on its own.

Similar Messages

  • How to copy a playlist from iTunes to a USB (keeping artist song name etc) and the files to listen and browse in a jeep hard drive

    I made a music playlist on my iTunes, perfectly ordered. I get a car with a USB input to get the songs in the car hard drive, My question is: How can I copy the playlist (with artist, song etc) with the music file (but with the name and artist instead  of the file name) in the usb so I can copy it and browse it in my car?
    Thanks

    This would require renaming the files on the computer.
    iTunes is not going to do this magically when copying files to the flash drive, iTunes does not even copy/sync files to a flash drive.

  • TS3833 I am receiving this error when syncing my ipod: iTunes could not copy "song name" to the iPod "name" because an unknown error occurred (-50).  I am using iTunes version 10.6.3.25. Why?

    I am receiving this error when syncing my ipod: iTunes could not copy "song name" to the iPod "name" because an unknown error occurred (-50).  I am using iTunes version 10.6.3.25. Why?

    Right click the filename that won't download and selsct 'Get Info'. Look at the file path, does it have a //?// in it? That is a problem with Amazon downloads that prevent iTunes from finding the file. Use 'Add Folder' to add the album to your library and try syncing it again

  • How can i bulk rename music files in reverse order from artist - song name to songname - artist

    How can I bulk rename music files in reverse order from artist - song name to songname - artist.
    I actually dont need to rename the actual files.
    Its just i have a huge txt list of 100,000 music names that are listed as so..
    Artist - Song Name
    Artist - Song Name
    Artist - Song Name
    Artist - Song Name
    Artist - Song Name
    Artist - Song Name
    and i need this list to reverse it self so it is listed in the list as
    Song Name - Artist
    Song Name - Artist
    Song Name - Artist
    Song Name - Artist
    Song Name - Artist
    Song Name - Artist
    Song Name - Artist
    Im sure there is some kinda way to auto a mix of applescript/automator/terminal to do something like:  all char before the "-" replace with the chars after the "-".
    Please some one help me if you know how I can pull this off

    How can I bulk rename music files in reverse order from artist - song name to songname - artist.
    I actually dont need to rename the actual files.
    Its just i have a huge txt list of 100,000 music names that are listed as so.
    I wonder if we haven't misunderstood what you were asking for. Could it be that you have not a huge file, but just a huge list of names in many small files. If that's the case, you should rather use the following script instead of the previous one.
    Since this script does not rename the files, make a backup of your files before running it.
    set theFolder to choose folder -- the folder containing your text files
    tell application "Finder"
        set theNames to name of files of theFolder whose name extension is "txt"
    end tell
    set theTextFiles to {}
    set theFolderPath to POSIX path of theFolder
    repeat with thisName in theNames
        copy theFolderPath & thisName to the end of theTextFiles
    end repeat
    repeat with thisFile in theTextFiles
        set F1 to open for access thisFile
        set theText to read F1
        close access F1
        set theParagraphs to paragraphs of theText
        set bigList to (a reference to theParagraphs)
        set theNewParagraphs to {}
        set bigNewList to (a reference to theNewParagraphs)
        repeat with X in bigList
            set P to offset of " - " in X
            if P = 0 then
                set Y to X
            else
                set Y to text (P + 3) through -1 of X & " - " & text 1 through (P - 1) of X
            end if
            copy Y & return to the end of bigNewList
        end repeat
        set theNewText to text 1 through -2 of (bigNewList as text)
        set F2 to open for access thisFile with write permission
        set eof F2 to 0
        write theNewText to F2
        close access F2
    end repeat
    display dialog "Done!" buttons {"OK"} default button 1 with icon 1
    Message was edited by: Pierre L.

  • "Error occurred while converting the file 'song name'. The required disk cannot be found"

    Hi, I saw this issue in an archived discussion, and I just had the same problem, but figured out how to resolve it.
    I think this error is a result of:
    A) downloading a new version of iTunes, and;
    B) storing my iTunes library on an external hard drive.
    Because when the new version of iTunes was downloaded, I found that the destination folder for my iTunes music was no longer selected. Therefore, I was getting the error message: "Error occurred while converting the file 'song name'. The required disk cannot be found" when I tried to import CDs.
    To fix: go to:
    iTunes>Preferences>Advanced
    and specify your destination folder for your music.
    Just wanted to share!

    Thank you so much! I was in the same situation (iTunes library stored on external hard disk). Strangely, iTunes knew where my music was stored (i.e. if I clicked a song it would link to the library location and play with no problems). But in the "Advanced" settings, the location of my iTunes Library was blank. So I just pointed to the correct location and now everything is working OK! Thanks again.

  • ITunes could not copy "Song Name" to the iPhone because an unknown error occurred (-50)

    Recently when I tried syching one of my playlists into my iPhone 4 (Running on 5.1) using iTunes 11.2.0.26 for Windows (Windows XP SP3), I have been having a problem with some songs I acquired recently.  It will sync all the other songs, but when it reaches the song in question, the following error message pops up:
    "iTunes could not copy "Name of Song" to the iPhone because an unknown error occurred (-50)"
    After which, it stops synching songs altogether.
    I tried TWO different USB connectors (BOTH from Apple), and the error still occurs.  When I remove the song in question, ALL songs sync normally.
    I used the 'Get Info' option to see if there was something in the way the song was coded.  This info is from one of the songs that gets synched normally:
    Kind:                  MPEG Audio file
    Size:                  11 MB
    Bit Rate:            256 kbps
    Sample Rate:     44.100 kHz
    Date Modified:    12/20/2009  4:33 PM
    Plays:               1
    Last Played:      1/22/2010  8:40 PM
    Format:             MPEG-1, Layer 3
    Channels:          Stereo
    ID3 Tag:            v2.3
    Encoded with:   LAME
    THIS is the info on the problematic song:
    Kind:                  MPEG Audio file
    Size:                  8.2 MB
    Bit Rate:            256 kbps
    Sample Rate:     44.100 kHz
    Date Modified:    5/1/2013  6:12 PM
    Plays:               1
    Last Played:      5/3/2013  8:40 PM
    Format:             MPEG-1, Layer 3
    Channels:          Joint Stereo
    ID3 Tag:            v2.3
    Encoded with:   LAME3.96
    By the way, BOTH song (The ones synching normally, and this unsynching song), where purchased and downloaded from Amazon.com.
    ANY information that will help me solved this problem will be VERY appreciated.  Likewise, if you need any additional information, please let me know...
    Thanks for your time.

    Try going through other threads on topic
    http://www.google.com/search?source=ig&hl=en&rlz=&=&q=becausean+unknown+error+occurred+%28-50%29+iphone&btnG=Google+Search&aq=f&oq=#sclient=p sy&hl=en&newwindow=1&safe=off&source=hp&q=because+an+unknown+error+occurred+%28- 50%29+iphonesite:apple.com&aq=f&aqi=&aql=&oq=&gs_rfai=&pbx=1&fp=9bef8cda26d1a6ec

  • ITunes mixing up song names and the album artworks.

    This is hard to explain but I'll do my best. For the record, I have 2 iPods that sync with the same playlist (iPod Touch 2nd Gen 4.2.1 for main music and iPod Nano 5th Gen for excercise). I decided to rip a recently purchased CD today and sync it to my iPod. I opened iTunes like normal and I noticed a bunch of unwanted songs in my playlist I use for my iPods. Upon investigation, I noticed the songs are my normal songs, but iTunes has given them the title and album art of a different song in my library. When I click Get Info the correct song name appears in the title box. When I click ok to get out of that menu, the song returns back to the normal title, artist, and artwork. (An example, a song titled Amarillo Sky by Jason Aldean was really Do I by Luke Bryan. When I left Get Info, the song corrected its info back to Do I) After rebuilding my entire playlist and having to re-locate several songs that were now listed under incorrect titles and artists, I syned my iPod nano and realized that some of the songs under the "Songs" category aren't in alphebetical order like they should be. This really bugs me as I like my songs to be in order. To make matters worse, iTunes insists on changing some of the songs back to the incorrect title after I fixed them (Love in an Elevator by Aerosmith keeps getting turned into Eat the Rich by Aerosmith). Any suggestions to fix this ordeal?

    Try signing out of the iTunes store. If that doesn't work try rolling back to an older version of your iTunes database as described in Empty/corrupt library after upgrade/crash.
    tt2

  • Can I copy a song then change the settings?

    After copying a song from one playlist to another, is there a way to make iTunes think it's a different song? I want to change some equalization settings on the copy but not the original.

    Im having the same problem, but on a Mac. It seemed to me it would be easy enough to make a copy of a song so can edit the duplicate, but I just could not do it.
    I tried putting it on my desktop and changing the name, adding it to my library again assuming it would import it like a new song but it did not.
    I looked for some sort of "duplicate song" option but did not find one, also tried copy-paste but that did not work (dont know what that copy is for!).
    Hope someone could help.

  • Mac recognizing artist, song name, etc.

    i'm trying to load up itunes on my wife's mac, i use a PC for myself. Don't know why, but the computer is not reading artist name, album, song name off of the cd's. Everything goes on to itunes as unidentified track 1, 2. 3 etc. Is there some setting that I'm missing?

    Is the Mac connected to the internet when you are importing your CDs? iTunes picks up the track information from an online database. It will do this automatically if you are connected while you are importing or you can do it afterwards by connecting to the internet, highlighting the tracks and going to Advanced>Get CD Track names: iTunes for Mac- I don't see the names of songs
    Also, what sort of CDs are they, commercial CDs or CD-Rs? If they are mixed ones you made yourself on another computer the track names will be seen as Track 01, Track 02 etc. and the information has to be keyed in again by hand (unless someone uploaded the information to the CD database): How iTunes remembers Audio CDs

  • How to copy a JS variable to the clipboard

    I have a script that determines the distance between two guides.
    I would like that variable to be copied to the clipboard so that a user can enter it into the control panel if one wishes.
    The copy() function will only copy something that is selected in the ID file itself.
    Any hints on how to start?
    Thanks,
    Tom

    Hello,
    I took up try67's suggestion because I cannot find any property that will copy to the clipboard.
    The following works fine...for one number! A five digit number with a decimal (or even just two digits) overflows the text box. Text that overflows cannot be selected.
    I think that the easiest solution is to make the pointSize of the text really small but for the life of me I cannot decipher how to do that.
    Any suggestions on adding one or two lines to solve this? I figure the best place to put this property is in the frameProps property record.
    Tom
    var a = 7;
    numToCopy(a);
    function numToCopy(numToCopy){
    var frameProps = {contents:numToCopy.toString()}
    var myTextFrame = app.activeDocument.textFrames.add(frameProps);
    myTextFrame.words.everyItem().select();
    app.copy();
    myTextFrame.select();
    myTextFrame.remove();
    }//end function numToCopy

  • Why Can't I See The Artist's Name In The Media Centre Play Mo

    I'm listening to my Zen Touch on my computer at work. I'm playing my music through Media Centre and cannot see the Artists' Name in the player. I only get a number (the number of the file within the player, I presume).
    Anyway to correct this problem? I'm sorry if this is covered in any new update. I didn't see it in the list of descriptions.

    I assume that you are refering to the Creative MediaSource Player/Organizer. In this case, you can view the Artist name of the track in the Now Playing window. You need to make your Now Playing window wider so that you can see the Artist column.

  • Bring back artist/song info in the title bar (Desktop)

    Why would you remove that feature? Now it just says "Spotify Premium". I'd honestly like to hear the logic behind this.

    I love Spotify and as many others here use it to listen to music while at work, so having a preview of artist/song is handy. I just can't think how replacing this info with a static title would be an improvement. I'm really curious to know why that decision was made and the thinking behind it? 
    Otherwise, keep up the good work. CheersSkumberg wrote:
    Why would you remove that feature? Now it just says "Spotify Premium". I'd honestly like to hear the logic behind this.  

  • Software to assist with editing artist info and song names in the library?

    Does any such thing exist?
    Thanks.

    do i have to be online when i take music from a cd?
    Not necessarily.
    Go to iTunes prefs -> Advanced - Importing. Select Automatically look up track names from internet.
    This will look them up when you insert a CD.
    For those you have already imported, select the songs, then menu Advanced -> Get CD track names.

  • View artist songs alphabetically in the store

    When I search in the iTunes Store for songs by a particular artist, how do I view the songs in alphabetic order? Some artists have hundreds and it is quite tedious to scroll through them all. What happened to advanced search? 

    With the newest update, 11.0.2, I can now view songs alphabetically. Now If Apple could only bring back the power search!

  • Needed: Script to copy Photo album name into the comments field for pix

    I was never in the habit of applying anything to photo comments, but gave my albums a desriptive name so I knew what they were. Now I wish I had because album titles are not searchable. I'm wondering if anyone knows how to create an Automator workflow or Applescript that could take the Album Name and apply it to the comments field for each picture in the album. I have over 25,000 pictures and quite a few albums. I've started to do it manually for each album but would love to find a quicker way to accomplish this.
    Thanks.

    This should do the trick for you:
    click here to open this script in your editor<pre style="font-family: 'Monaco', 'Courier New', Courier, monospace; overflow:auto; color: #222; background: #DDD; padding: 0.2em; font-size: 10px; width:400px">tell application "iPhoto"
    set theAlbums to (every album)
    repeat with thisAlbum in theAlbums
    set thisAlbumName to the name of thisAlbum
    set thePhotos to (every photo of thisAlbum)
    repeat with thisPhoto in thePhotos
    set comment of thisPhoto to thisAlbumName
    end repeat
    end repeat
    end tell</pre>
    FYI, it will step through every album; get its name; and then step through every photo in the album and change the comments to the album's name.
    I recommend that you make a back-up before proceeding!

Maybe you are looking for

  • Vendor Replication and Different Back-end Systems

    Hello, Currently, we have vendor replication were the vendor number from the back-end is used in SRM-EBP.  Now, we want add another back-end but there are vendor number conflicts.  Is there a way to configure it so that the new back-end replicaition

  • HT2478 how to edit the picture you put on the desktop, center it etc.

    how to edit the picture you put on the desktop, center it etc.

  • Qosmio G30-E10: Display resolution switches from 1920x1200 to 1024x768

    Hello, Qosmio G30-E10 Display resolution switches sometimes from 1920x1200 (my default) to 1024x768 after returning from Standby or Hibernation i run Vista Ultimate, newest Display Driver from Toshiba Download Area. This doesn't happened any time, bu

  • Network connection ok, no internet...

    I had a WDS with an AExtreme as main and two AExpress as relay and remote WEP encryption all working OK... Now I got a Time Capsule so I reset the whole network: TC as main, AExtreme as relay and AExpress as remote, WPA: it worked perfect for one day

  • Problem printing production order.

    Hi  guys this is my first post. i have a problem  printing production orders.when i give a print. its printing only 2 or  3 line.what should i do to add  some more information to my production order.and where can i view the print preview of my produc