INTERACT FORUM
Windows => Plug-in Development => Topic started by: SBrandsborg aka Mouseman on September 27, 2003, 05:49:53 am
-
hi
whats the easyest way to rename a label to the title mc is playing???
-
I dont understand the question
-
if i make a
label1.caption = (SOMETHING)
SOMETHING shall be the title of the playing song
-
oh
I don't think there is a direct way in doing this
I do not remember how it can be done but i know it can be.
if you remember someone made a "Listening to:" plug-in and i asked him how he did it and he told me but i lost the message.
-
anyone?
i just need to know what command i need to get the title, artist etc on my plugin...
i cant find out the automation
hehe
i think its something like
MJFileAutomation.Name()
but i cant get it work :s
-
Hi, Mouseman. Try this....
cmjAutomation = 'whatever VB code you need to get ahold of a CMJAutomation COM object
curPlaylistAutomation = cmjAutomation.GetCurPlaylist()
curPlayingNowIndex = curPlaylistAutomation.Position() 'this is an integer
curFile = curPlaylistAutomation.GetFile(curPlayingNowIndex) 'Now you have a CMJFileAutomation object.
titleLabel.caption = curFile.Name()
artistLabel.caption = curFile.Artist()
albumLabel.caption = curFile.Album()
' etc. etc.
The above is untested code, as I do not use VB, but hopefully the idea is clear.
Regards,
Soundman
-
still haveing alot of problems.. i have looked abit at the busybox sdk
and come up with
Dim MJCurPlaylist As MediaJukebox.MJCurPlaylistAutomation
Set MJCurPlaylist = g_MJ.GetCurPlaylist
' get the file
Dim MJFile As MediaJukebox.MJFileAutomation
Set MJFile = MJCurPlaylist.GetFile(z)
Label1.Caption = MJFile.Name
but its not what i need... i need it to display what song im playing right now..
Thanks soundman BUT i cant undestand your code hehe :s
-
It's pretty easy to do :)
Have a look at the Example (BusyBox) for how to get the info on the playing now tracks.
Then just assign the name of the file to the label.
-
can anyone make an exampel?