Shoutbox

Changing user display picture - Printable Version

-Shoutbox (https://shoutbox.menthix.net)
+-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58)
+--- Forum: Messenger Plus! for Live Messenger (/forumdisplay.php?fid=4)
+---- Forum: Scripting (/forumdisplay.php?fid=39)
+----- Forum: Plug-Ins (/forumdisplay.php?fid=28)
+------ Thread: Changing user display picture (/showthread.php?tid=46482)

Changing user display picture by Dick Donny on 06-17-2005 at 10:18 PM

Hi

Just hoping on the off chance someone may have already figured this out ... I would like to replace the user picture with an image determined via code (ie a plugin).

I've discovered that the images are stored in the tiles directory under application settings, and it looks like they are compressed during this process.  However, I can't work out how to determine which one is the active tile, nor how to get a new picture in there in the correct format.  Not tried yet, but also unsure how to force a reload/refresh of the picture.

Any advice would be appreciated.


RE: Changing user display picture by Plik on 06-17-2005 at 10:29 PM

IIRC, you used to be able to do this using the messenger api with this code:

code:
oMessenger.MyPropery(2) = <location of file>
with oMessenger beeing and instance of the MessengerAPI
not sure if this code is still compatable with the newer versions of messenger.

Also, the images stored in the tiles directory are just png's renamed to dat's. But to use the directory to add a display picture you have to edit the map.dat file, which is encrypted. So the api method is the best way to change the display picture (assuming it still works)

Hope this helps, and please post back here if you're having any problems.
RE: Changing user display picture by Dick Donny on 06-17-2005 at 10:41 PM

Thanks for the reply.

Unfortunately this now raises an error |-) .... but it does give me a place to start so thanks again.

Has anybody else any suggestions?


RE: Changing user display picture by Eljay on 06-22-2005 at 05:00 PM

oMessenger.MyProperty(2) = <location of file>

in case the error was just because madman missed a t :P


RE: Changing user display picture by matty on 06-22-2005 at 06:25 PM

code:
'This is just an example for calling the oMessenger object passed through the Initialize Function into a Variable.
'Make sure to set a reference to the MessengerAPI Type Library


Public WithEvents MessengerAPI As MessengerAPI.Messenger

Public Function Initialize( _
                           ByVal nVersion As Long, _
                           ByVal sUserEmail As String, _
                           ByVal oMessenger As Object _
                          ) As Boolean
    Initialize = True
    Set MessengerAPI = oMessenger
    ' This will set the Display Picture to Vortec Space.jpg (This is wallpaper from Windows XP)
    MessengerAPI.MyProperty(2) = "C:\Windows\Web\Wallpaper\Vortec space.jpg"
End Function


RE: Changing user display picture by Dick Donny on 06-23-2005 at 07:41 PM

OK guys ... thanks for your suggestions and all that, but maybe I am not just been very clear.

I am using version 7 and the sdk documentation clearly states that the MyProperty method is reserved ... ie read only

Error Code 0x80070057 Returned in all cases. This method is reserved for future use.

Just to be 100% clear ... I confirmed this with a noddy application.

Can anybody suggest another method to do this?

Thanks


RE: Changing user display picture by TheBlasphemer on 06-23-2005 at 07:55 PM

Which version of MSN Messenger are you using?


RE: Changing user display picture by Dick Donny on 06-23-2005 at 07:58 PM

version 7 ..... build 7.0.0813 :)