mcmusic
09-19-2011, 02:22 PM
I am a total noob to JS and need a little help.
Currently writing some small snippets to control iTunes.
An example:
var iTunesApp = WScript.CreateObject("iTunes.Application");
iTunesApp.LibraryPlaylist.AddFile('B:\\filetoadd.mp4');
Nicely adds a file to the library.
Now, i need to set the encoder. I try this:
var iTunesApp = WScript.CreateObject("iTunes.Application");
iTunesApp.CurrentEncoder("MP3");
I get: object doesn't support this property of method.
iTunes SDK docs:
HRESULT IiTunes::CurrentEncoder ( [in] IITEncoder * iEncoder )
Sets the current encoder (AAC, MP3, AIFF, WAV, etc.).
Parameters:
iEncoder An IITEncoder object corresponding to the new encoder.
Any ideas?
Currently writing some small snippets to control iTunes.
An example:
var iTunesApp = WScript.CreateObject("iTunes.Application");
iTunesApp.LibraryPlaylist.AddFile('B:\\filetoadd.mp4');
Nicely adds a file to the library.
Now, i need to set the encoder. I try this:
var iTunesApp = WScript.CreateObject("iTunes.Application");
iTunesApp.CurrentEncoder("MP3");
I get: object doesn't support this property of method.
iTunes SDK docs:
HRESULT IiTunes::CurrentEncoder ( [in] IITEncoder * iEncoder )
Sets the current encoder (AAC, MP3, AIFF, WAV, etc.).
Parameters:
iEncoder An IITEncoder object corresponding to the new encoder.
Any ideas?