Script Device.StartSynch Not working

This forum is for questions / discussions regarding development of addons / tweaks for MediaMonkey.

Moderator: Gurus

Posts: 4
Joined: Mon Oct 11, 2010 8:54 am

Script Device.StartSynch Not working

Post by JohnPaulJones » Wed Oct 13, 2010 6:38 am

Hi All,

I have the following code which should in theory send the new song to my ipod. The new SongList is created and works correctly, and the synchronisation kicks off - both the bottom bar in Media Monkey and the ipod show that a file (the correct one) is being synchronised.

The sync never finnishes trying to copy the file over - is there something I am missing in the creation of the new song, or am I missing something out on the StartSynch call? The code runs without error but no updated songs?! If I drag and drop the same song using media monkeys interface there is not a problem. If I create the song from a song already on the ipod the synch works correcly, so it looks to me that the issue is in copying the actual file to the ipod?

Song Creation is:

Code: Select all

SongsDB.SDBApplicationClass SDB = new SongsDB.SDBApplicationClass();
                SDB.ShutdownAfterDisconnect = true;

SongsDB.SDBSongIterator songs = (SongsDB.SDBSongIterator)SDB.Database.QuerySongs("ID=4");
                newSongList = SDB.NewSongList;                
                while (!songs.EOF)
                    SongsDB.SDBSongData song = songs.Item;

SDB.Device.StartSynch(deviceHandle, newSongList);

Does anyone have any ideas?

Posts: 10024
Joined: Fri Aug 26, 2005 3:28 am
Location: Hull, UK

Re: Script Device.StartSynch Not working

Post by trixmoto » Sat Mar 09, 2013 2:01 pm

Sorry, I don't, but I am interested in this method. I'm wondering if there's a way to use it to trigger a full automatic sync? I'm also wondering what the "device handle" is - is it the DeviceInst?
Download my scripts at my own MediaMonkey fansite.
All the code for my website and scripts is safely backed up immediately and for free using Dropbox.

Posts: 301
Joined: Sun Oct 05, 2008 4:46 pm
Location: Switzerland

Re: Script Device.StartSynch Not working

Post by Aff » Sun Mar 10, 2013 12:42 pm

I didn't get anything to work regarding device classes from a script. :(
I'd be interested as well if I don't have to write a DLL. (Even though my sync back scripts may reach the end of their life cycle as MMA is growing up).

Posts: 3199
Joined: Fri Mar 09, 2007 9:00 am

Re: Script Device.StartSynch Not working

Post by Ludek » Mon Mar 11, 2013 6:14 am

This is not possible, added as to Mantis

Post Reply