Advertisement
westor

$get_song for itunes

Nov 16th, 2014
356
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
mIRC 0.39 KB | None | 0 0
  1. alias get_song {
  2.   .comopen Song iTunes.Application
  3.   if ($comerr) { goto error }
  4.   if ($com(Rating,CurrentTrack,3,dispatch* Track)) {
  5.     if (!$com(Track)) { goto error }
  6.     var %k = $com(Track,Name,2)
  7.     var %name = $remove($com(Track).result,$chr(42),$chr(45))
  8.   }
  9.   :error
  10.   while ($com(0)) { .comclose $com(1) }
  11.   if (%name) { return %name }
  12.   elseif (!%name) { return 0 }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement