Skype And MediaMonkey!

Post a reply

Visual Confirmation

To prevent automated access and spam, you are required to confirm that you are human. Please place a check mark next to all images of monkeys or apes. If you cannot see any images, please contact the Board Administrator.

Smilies
:D :) :( :o :-? 8) :lol: :x :P :oops: :cry: :evil: :roll: :wink:
BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON
Topic review
   

Expand view Topic review: Skype And MediaMonkey!

Re: Skype And MediaMonkey!

Post by UksusoFF » Wed Oct 26, 2011 3:31 pm

Not worked for MM4 :(
Image Image

Re: Skype And MediaMonkey!

Post by reboho » Fri Dec 03, 2010 4:33 pm

Nevermind, figured it out. SDB.Player.CurrentSong.AlbumName is correct, works like I was hoping.

Re: Skype And MediaMonkey!

Post by reboho » Thu Dec 02, 2010 4:24 pm

Is there an SDB.Player.CurrentSong.AlbumName? I would prefer that to song length. I already modified the MoodPrefix to be "(music)" but I would like to take it a step further and replace the song time length with the album name.

Re: Skype And MediaMonkey!

Post by floorman » Wed Aug 27, 2008 2:09 pm

Solved...

Obviously the problem was (once again) in front of the screen :oops: :roll: I have completely forgotten I have the AMIP plugin installed in the MM. After disabling it the script works like the Swiss watch. Sorry for causing the panic :)

Re: Skype And MediaMonkey!

Post by floorman » Tue Aug 05, 2008 1:55 am

Damn... forgot to logon on the previous post. I'm adding the screenshot as well.
Image
Image

Re: Skype And MediaMonkey!

Post by Guest » Tue Aug 05, 2008 1:47 am

Peke wrote:Copy/paste script here so that we can look at it?


Here you go:

Code: Select all
    ''==========================================================================
    ' NAME: SkypePlayMood v1.3 (SkypeMoodText.vbs)
    '
    ' AUTHOR : Peke
    ' ORIGINAL DATE : 10.10.2006
    '
    ' ÇO-AUTHOR : Cran
    ' UPDATED : 30.01.2008
    ' INSTALL: Download and install Skype4COM Release (https://developer.skype.com/Download)
    '          Save This Script in MM\Scripts\Auto folder and restart MM
    ' NOTE   : Use latest Skype and allow MM to access Skype
    '
    ' UPDATES:
    ' v1.3:
    '-------
    ' - revert to original mood when pausing or stopping playback
    ' - fix script error when closing MediaMonkey with no track.
    '==========================================================================
    Dim MoodPrefix, AppOriginal, MediaMonkeyMoodFirst

    'Edit MoodPrefix if you want to have Custom Prefix of now Playing Track
    MoodPrefix = "Now playing: "

    ' Append Original Mood text to MediaMonkey Mood Text (Default TRUE)
    AppOriginal = True

    ' Used only if Appending To original Mood Text is TRUE. Change this if you wish that
    ' MediaMonkey Mood Text is added to Original Mood Text(Default True)
    MediaMonkeyMoodFirst = True

    '// Attach To MMObject For Debbuging Only
    'Dim SDB
    'Set SDB = CreateObject("SongsDB.SDBApplication")

    ' Added by Cran
    Dim OldMsg

    Sub OnStartup
      '// Start the Skype client if not Running
      Dim ini, list, list2
      Set ini = SDB.IniFile

      '//Save Skype Mood text to revert on MM Exit
      Set list = GetObject("winmgmts:")
      Set list2 = list.ExecQuery("Select * from Win32_Process where name like 'Skype%'")
      If list2.count > 0 Then
        '// Create a Skype4COM object:
        Set oSkype = CreateObject("Skype4COM.Skype")
        If InStr(oSkype.CurrentUserProfile.MoodText,MoodPrefix) = 0 Then
          ini.StringValue("SkypeMood","OldMsg") = oSkype.CurrentUserProfile.MoodText
        End If
      End If
      Call Script.RegisterEvent(SDB, "OnPlay", "SetSkypeMood")
      Call Script.RegisterEvent(SDB, "OnShutdown", "RevertSkypeMood")
      ' Added by Cran : revert to original skype mood
      Call Script.RegisterEvent(SDB, "OnStop", "RevertSkypeMood")
      Call Script.RegisterEvent(SDB, "OnPause", "RevertSkypeMood")
    End Sub

    Sub SetSkypeMood
      Dim ini, list, list2
      Set ini = SDB.IniFile
      Set list = getobject("winmgmts:")
      Set list2 = list.ExecQuery("Select * from Win32_Process where name like 'Skype%'")
      If (list2.count > 0) Then
        '// Create a Skype4COM object:
        Set oSkype = CreateObject("Skype4COM.Skype")
        '//Set Skype Mood text to show now playing
        If Not ((InStr(oSkype.CurrentUserProfile.MoodText,MoodPrefix) > 0) Or (ini.StringValue("SkypeMood","OldMsg") = oSkype.CurrentUserProfile.MoodText)) Then
          ini.StringValue("SkypeMood","OldMsg") = oSkype.CurrentUserProfile.MoodText
         OldMsg = oSkype.CurrentUserProfile.MoodText
        End If
        If AppOriginal Then
          If MediaMonkeyMoodFirst Then
            oSkype.CurrentUserProfile.MoodText = MoodPrefix &SDB.Player.CurrentSong.ArtistName &" - " &SDB.Player.CurrentSong.Title &" (" &SDB.Player.CurrentSong.SongLengthString &")" &Chr(13) &Chr(10) &ini.StringValue("SkypeMood","OldMsg")
          Else
            oSkype.CurrentUserProfile.MoodText = ini.StringValue("SkypeMood","OldMsg") &Chr(13) &Chr(10) &MoodPrefix &SDB.Player.CurrentSong.ArtistName &" - " &SDB.Player.CurrentSong.Title &" (" &SDB.Player.CurrentSong.SongLengthString &")"
          End If
        Else
          oSkype.CurrentUserProfile.MoodText = MoodPrefix &SDB.Player.CurrentSong.ArtistName &" - " &SDB.Player.CurrentSong.Title &" (" &SDB.Player.CurrentSong.SongLengthString &")"
        End If
      End If
    End Sub

    Sub RevertSkypeMood
      ' The Sub doesn't crash anymore, but for 'production'
      ' code, but you know, user experience has to stay pleasant
      ' even if the code bombs.
      On Error Resume Next
      '// Start the Skype client if not Running
      Dim ini, list, list2
      Dim sOldMsg
      Set ini = SDB.IniFile

      Set list = getobject("winmgmts:")
      Set list2 = list.ExecQuery("Select * from Win32_Process where name like 'Skype%'")
      If list2.count > 0 Then
        '// Create a Skype4COM object:
        Set oSkype = CreateObject("Skype4COM.Skype")
       If Not( ini Is Nothing ) Then
          sOldMsg = ini.StringValue("SkypeMood","OldMsg")
          If  sOldMsg = "" Then
             sOldMsg = OldMsg
          End If
       Else

       End If
       If Not( oSkype Is Nothing) Then
          '//revert saved Skype Mood
          oSkype.CurrentUserProfile.MoodText = sOldMsg
          '// Clear Saved mood
       End if
      End If
    End Sub

Re: Skype And MediaMonkey!

Post by sakurakessho » Sat Jul 26, 2008 11:33 pm

For those of you wanting full IM support check out Digsby. It always detects MM's now playing for tis 'listening to' feature.

Re: Skype And MediaMonkey!

Post by Peke » Tue Jul 22, 2008 4:13 pm

Copy/paste script here so that we can look at it?

Re: Skype And MediaMonkey!

Post by floorman » Tue Jul 22, 2008 10:50 am

Whatever I edit in the script my Skype mood window alway shows this:
"np: Artist - Track name"

Any ideas why?

Post by pelle3 » Thu Mar 20, 2008 1:03 am

Peke wrote::D Easy isn't it ? Welcome to world of Scripts.


Thanks :D

Post by Peke » Tue Mar 18, 2008 4:46 pm

:D Easy isn't it ? Welcome to world of Scripts.

Post by pelle3 » Mon Mar 17, 2008 3:19 pm

Thanks for the script! Is there a way to let it show the album title and the information in the "Year" tag?

Cheers,
pelle3

Edit:

Got it.

&SDB.Player.CurrentSong.AlbumName &" (" &SDB.Player.CurrentSong.Year &" )"

Post by Guest » Sun Feb 10, 2008 7:59 am

excellent

Post by Cran » Thu Jan 31, 2008 1:14 am

Thanks for the credit !
But to be honest, I just fixed very few lines in your
script ... :)

While reading the changes, I noticed that the message is still in french !
I suggest to change line :
Code: Select all
MoodPrefix = "L'humeur du moment : "

to
Code: Select all
MoodPrefix = "Now playing: "


I added a screenshot of the skype mood area updated
by the script with the current MediaMonkey track :

Image

Post by Peke » Wed Jan 30, 2008 10:05 pm

THX, I thought that people abandoned this script :) I added small changes for you
Code: Select all
''==========================================================================
' NAME: SkypePlayMood v1.3 (SkypeMoodText.vbs)
'
' AUTHOR : Peke
' ORIGINAL DATE : 10.10.2006
'
' ÇO-AUTHOR : Cran
' UPDATED : 30.01.2008
' INSTALL: Download and install Skype4COM Release (https://developer.skype.com/Download)
'          Save This Script in MM\Scripts\Auto folder and restart MM
' NOTE   : Use latest Skype and allow MM to access Skype
'
' UPDATES:
' v1.3:
'-------
' - revert to original mood when pausing or stopping playback
' - fix script error when closing MediaMonkey with no track.
'==========================================================================
Dim MoodPrefix, AppOriginal, MediaMonkeyMoodFirst

'Edit MoodPrefix if you want to have Custom Prefix of now Playing Track
MoodPrefix = "L'humeur du moment : "

' Append Original Mood text to MediaMonkey Mood Text (Default TRUE)
AppOriginal = True

' Used only if Appending To original Mood Text is TRUE. Change this if you wish that
' MediaMonkey Mood Text is added to Original Mood Text(Default True)
MediaMonkeyMoodFirst = True

'// Attach To MMObject For Debbuging Only
'Dim SDB
'Set SDB = CreateObject("SongsDB.SDBApplication")

' Added by Cran
Dim OldMsg

Sub OnStartup
  '// Start the Skype client if not Running
  Dim ini, list, list2
  Set ini = SDB.IniFile

  '//Save Skype Mood text to revert on MM Exit
  Set list = GetObject("winmgmts:")
  Set list2 = list.ExecQuery("Select * from Win32_Process where name like 'Skype%'")
  If list2.count > 0 Then
    '// Create a Skype4COM object:
    Set oSkype = CreateObject("Skype4COM.Skype")
    If InStr(oSkype.CurrentUserProfile.MoodText,MoodPrefix) = 0 Then
      ini.StringValue("SkypeMood","OldMsg") = oSkype.CurrentUserProfile.MoodText
    End If
  End If
  Call Script.RegisterEvent(SDB, "OnPlay", "SetSkypeMood")
  Call Script.RegisterEvent(SDB, "OnShutdown", "RevertSkypeMood")
  ' Added by Cran : revert to original skype mood
  Call Script.RegisterEvent(SDB, "OnStop", "RevertSkypeMood")
  Call Script.RegisterEvent(SDB, "OnPause", "RevertSkypeMood")
End Sub

Sub SetSkypeMood
  Dim ini, list, list2
  Set ini = SDB.IniFile
  Set list = getobject("winmgmts:")
  Set list2 = list.ExecQuery("Select * from Win32_Process where name like 'Skype%'")
  If (list2.count > 0) Then
    '// Create a Skype4COM object:
    Set oSkype = CreateObject("Skype4COM.Skype")
    '//Set Skype Mood text to show now playing
    If Not ((InStr(oSkype.CurrentUserProfile.MoodText,MoodPrefix) > 0) Or (ini.StringValue("SkypeMood","OldMsg") = oSkype.CurrentUserProfile.MoodText)) Then
      ini.StringValue("SkypeMood","OldMsg") = oSkype.CurrentUserProfile.MoodText
     OldMsg = oSkype.CurrentUserProfile.MoodText
    End If
    If AppOriginal Then
      If MediaMonkeyMoodFirst Then
        oSkype.CurrentUserProfile.MoodText = MoodPrefix &SDB.Player.CurrentSong.ArtistName &" - " &SDB.Player.CurrentSong.Title &" (" &SDB.Player.CurrentSong.SongLengthString &")" &Chr(13) &Chr(10) &ini.StringValue("SkypeMood","OldMsg")
      Else
        oSkype.CurrentUserProfile.MoodText = ini.StringValue("SkypeMood","OldMsg") &Chr(13) &Chr(10) &MoodPrefix &SDB.Player.CurrentSong.ArtistName &" - " &SDB.Player.CurrentSong.Title &" (" &SDB.Player.CurrentSong.SongLengthString &")"
      End If
    Else
      oSkype.CurrentUserProfile.MoodText = MoodPrefix &SDB.Player.CurrentSong.ArtistName &" - " &SDB.Player.CurrentSong.Title &" (" &SDB.Player.CurrentSong.SongLengthString &")"
    End If
  End If
End Sub

Sub RevertSkypeMood
  ' The Sub doesn't crash anymore, but for 'production'
  ' code, but you know, user experience has to stay pleasant
  ' even if the code bombs.
  On Error Resume Next
  '// Start the Skype client if not Running
  Dim ini, list, list2
  Dim sOldMsg
  Set ini = SDB.IniFile

  Set list = getobject("winmgmts:")
  Set list2 = list.ExecQuery("Select * from Win32_Process where name like 'Skype%'")
  If list2.count > 0 Then
    '// Create a Skype4COM object:
    Set oSkype = CreateObject("Skype4COM.Skype")
   If Not( ini Is Nothing ) Then
      sOldMsg = ini.StringValue("SkypeMood","OldMsg")
      If  sOldMsg = "" Then
         sOldMsg = OldMsg
      End If
   Else

   End If
   If Not( oSkype Is Nothing) Then
      '//revert saved Skype Mood
      oSkype.CurrentUserProfile.MoodText = sOldMsg
      '// Clear Saved mood
   End if
  End If
End Sub

Top

cron