mIRC Homepage
Posted By: Want dialog mp3help - 02/04/04 09:49 PM
im making an mp3 player and i was wondering how would i get the $insong.pos to continously get put into a list or combo box.
Posted By: jacksparrow2 Re: dialog mp3help - 03/04/04 12:19 AM
try to use the command Did

for ej Did -ra 1 1 %yourvar

or search on mirc help /did
Posted By: Hammer Re: dialog mp3help - 03/04/04 02:42 AM
You want the position number to be constantly added to a combo/list? $insong.pos returns the number of milliseconds into the currently playing file...not a very useful thing to add, as text, to a combo/list.

However, if that really is what you wish to do, you need to use a timer to constantly update the listbox with your $insong.pos.

.timerMP3 0 1 did -ra MP3Player 1 $!insong.pos

This breaks down as follows:
.timerMP3 is the named timer (so you can stop it easily whenever you need to)
0 means repeat forever, or until you stop it
1 means after 1 second
did -ra means remove all lines from the listbox and add the following line
MP3Player is the name of the dialog that you are using
1 is the listbox ID
$!insong.pos the $! makes the timer not evaluate $insong.pos until it's ready to run each time.
Posted By: Want Re: dialog mp3help *DELETED* - 03/04/04 07:37 AM
Post deleted by Want
Posted By: Want Re: dialog mp3help - 03/04/04 07:50 AM
easy conversion though
.timerMP3 0 1 /did -ra MP3Player 27 $!duration($calc($insong.pos / 1000))
thanks for the help hammer i never knew about the $!
© mIRC Discussion Forums