New scripting features in MM 2.5.2

Post a reply

Smilies
:D :) :( :o :-? 8) :lol: :x :P :oops: :cry: :evil: :roll: :wink:

BBCode is ON
[img] is ON
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: New scripting features in MM 2.5.2

by jiri » Thu Feb 01, 2007 12:41 pm

ParseText() is supposed to be used to fill in only empty fields (i.e. those that don't have any values set in tags). Therefore is works this way...

Jiri

by Steegy » Thu Feb 01, 2007 7:27 am

@Jiri, developers:
What's the status of the above mentioned "problem"?

by Steegy » Tue Jun 13, 2006 11:52 am

jiri wrote:
@Jiri
SDB.SongData.ParseText(...) doesn't work for the Artist, correct?
In the MainTracksWindows it is shown correctly after Parsing, but after refreshing, the Artist appeares untouched. For Title, ... it works well, thanks.

See http://www.mediamonkey.com/forum/viewto ... 6552#46552
Please empty the artist name (and best of all any field you expect to be filled in) before the function is called (i.e. track.ArtistName="").

Jiri
Will this be fixed? If it doesn't work to only use (track.ArtistName=""), then sometimes big workarounds (some fields have blank values "", 0, -1, ... ) would need to be used if it's impossible to know what field will receive a value. If only setting (track.ArtistName="") is enough, then I can live with that workaround very well.

by Steegy » Sun May 28, 2006 5:48 am

Yes, I PM'ed you with a link.

by jiri » Sun May 28, 2006 3:02 am

Do you have a full script code to test?

Jiri

by Steegy » Sat May 27, 2006 6:09 pm

Hello.

Just to say that the "activex event handling" error from the first page ( http://www.mediamonkey.com/forum/viewto ... 5903#35903 ) is still here (MM 2.5.3 RC3).
I'm using a ListView ActiveX control now. The event is executed correctly, but gives 2 same "useless" script event error messages. Even with an empty event handler function, as shown below.

Image

Code: Select all

Script.RegisterEvent ListView.Interf, "ItemClick", "OnArtistSelect3"

Sub OnArtistSelect3(ListItem)    
End Sub
Cheers
Steegy

by onkel_enno » Mon May 22, 2006 7:06 am

jiri wrote:Please empty the artist name (and best of all any field you expect to be filled in) before the function is called (i.e. track.ArtistName="").
Works like a charm. Thanks

by jiri » Mon May 22, 2006 6:10 am

@Jiri
SDB.SongData.ParseText(...) doesn't work for the Artist, correct?
In the MainTracksWindows it is shown correctly after Parsing, but after refreshing, the Artist appeares untouched. For Title, ... it works well, thanks.

See http://www.mediamonkey.com/forum/viewto ... 6552#46552
Please empty the artist name (and best of all any field you expect to be filled in) before the function is called (i.e. track.ArtistName="").

Jiri

by DiddeLeeDoo » Sun May 14, 2006 4:50 am

I believe there is an Idle status in the Windows System that can be retrieved.

The scripter needs to do a count down of the todo list for each item executed,

sketch

Code: Select all

DoneSoFar = 0

For i = 0 to ToDoList.Count-1
 If Idle then
   ToDoList.Task(i)
   DoneSoFar = DoneSoFar + 1
 Else
   Exit For
 End If
Next

ToDoList = ToDoList - DoneSoFar

by trixmoto » Sun May 14, 2006 4:27 am

I like the idea! :)

However, this would be complicated to manage because when the user started using MM again would you want to stop your idle event? You'd have to have some way of checking to see if MM was still idle in your loop so you could stop it maybe.

by DiddeLeeDoo » Sun May 14, 2006 3:14 am

Would it be an idea to add an OnIdle event, so certain events can simply create a 'to-do' list for whenever MM is idle, instead of doing it right away.

All in order to keep the speed up in MM

by Steegy » Sat May 13, 2006 10:20 am

Scripting Functionality Wishlist wrote:Events should also work with built-in tree nodes, or there should be some other way of making the tree context menu adaptable to the tree node that is right-clicked (e.g. show additional context menu items for certain nodes)
Will this work after the "event-can-only-have-one-handler" problem has been fixed? Or does it already work?

Cheers
Steegy

by onkel_enno » Thu May 11, 2006 6:08 am

@Jiri
SDB.SongData.ParseText(...) doesn't work for the Artist, correct?
In the MainTracksWindows it is shown correctly after Parsing, but after refreshing, the Artist appeares untouched. For Title, ... it works well, thanks.

See http://www.mediamonkey.com/forum/viewto ... 6552#46552

by jiri » Thu May 11, 2006 5:58 am

Ok, upon MM restart a timer pop up should come up...
Start playback, a pop up should come up. Modify any track except the one playing, a pop up should come up.
Modify the current playing track... a pop up should come up followed by 2 or 3 error messages "Error executing script event"....
This is indeed a bug and will be fixed. Thanks.
Is it possible to add also script related changes to the "Changes / What's new" list with new releases?
I'd like to better inform about scripting changes in the future versions. Possibly a special thread here would be good for this.

Jiri

by trixmoto » Thu May 11, 2006 5:37 am

I can confirm the bug, although I only get one error message!

I think some sort of history (probably only going back through 2.5 releases) to say what's been added and when. If not a past list, at least start one from now! :)

Top