TReKiE / msnp-sharp

Automatically exported from code.google.com/p/msnp-sharp
0 stars 0 forks source link

Broadcast avatar; Autosync is set to OFF. #85

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hello.

I am using MSNPSHARP_25 version and unfortunately I can't make users to 
see broadcasted avatar from MSNPSharp library.

I am adding the following code on SignedIn event

Image fileImage = Image.FromFile("avatar.jpg");
DisplayImage displayImage = new DisplayImage();
displayImage.Image = fileImage;
messenger.Owner.DisplayImage = displayImage;

No errors are thrown, but nobody can get the avatar.

Could you help me to figure it out?

Thanks.

Original issue reported on code.google.com by Flashbo...@gmail.com on 5 Feb 2009 at 2:17

GoogleCodeExporter commented 9 years ago
Only MSNP15 users can get your avatar. In, MSNP16, MSNP17, MSNP18 binary headers
changed so you cannot broadcast.

Read this:

http://msnpiki.msnfanatic.com/index.php/MSNC:Binary_Headers
(section WLM 2009)

Original comment by hepha...@gmail.com on 5 Feb 2009 at 2:28

GoogleCodeExporter commented 9 years ago
Even though my client uses MSN15 protocol and I am transmitting the avatar to 
MSNP18,17,16 users? 

Original comment by Flashbo...@gmail.com on 5 Feb 2009 at 2:33

GoogleCodeExporter commented 9 years ago
MSNP15(you) <> MSNP15(client) is supported for display picture... Official 
client
uses AppID=12 for display pictures and we don't answer to this application... 
Nobody
know what is this...

Original comment by hepha...@gmail.com on 5 Feb 2009 at 2:53

GoogleCodeExporter commented 9 years ago
I see, thanks for explanation.

I thought that this is possible to transmit display picture from MSNP15 to 
MSNP18, 
as there ought to be some back compatiblity

Original comment by Flashbo...@gmail.com on 5 Feb 2009 at 2:58

GoogleCodeExporter commented 9 years ago
I can see display picture. You can transmit display picture from MSNP15 to 
MSNP18...

from MSNP15 to 18 (ok)
but MSNP18 to MSNP18 not ok.

Original comment by hepha...@gmail.com on 5 Feb 2009 at 3:48

GoogleCodeExporter commented 9 years ago
Yea, but for provisioned account event MSN15 <> MSN15,MSNP18 is not OK :(

Original comment by Flashbo...@gmail.com on 7 Feb 2009 at 12:53

GoogleCodeExporter commented 9 years ago
I have managed to broadcast avatar from MSN15 to MSNP15. But MSN15<>MSNP18 
still 
won'y work, unfortunately

Original comment by msnquick...@gmail.com on 9 Feb 2009 at 10:23

GoogleCodeExporter commented 9 years ago
How did you managed?

Original comment by hepha...@gmail.com on 9 Feb 2009 at 3:11

GoogleCodeExporter commented 9 years ago
Since I have provisioned account, I have changed NSMessageHandler.cs
ContactService.SynchronizeContactList();
OnSignedIn(EventArgs.Empty);
on line 1548
I also don't know what is the real source of bug, so i decided to call whole 
SynchronizeContactList procedure, and it worked for MSN15, but MSN18 users cant 
see 
bot's avatar

Original comment by msnquick...@gmail.com on 9 Feb 2009 at 3:17

GoogleCodeExporter commented 9 years ago
Fixed. r845.

Original comment by hepha...@gmail.com on 10 Feb 2009 at 12:53

GoogleCodeExporter commented 9 years ago
I'm experiencing this issue with provisioned accounts. I checked out the most 
recent 
version r1008 and I can not set the display picture on the my provisioned 
account.

When the OnSignInCompleted() event handler is called I use the following code 
to set 
the display image:

Image fileImage = 
Image.FromFile(ConfigurationSettings.AppSettings["ImageFileName"]);
                DisplayImage displayImage = new DisplayImage();
                displayImage.Image = fileImage;
                m_Messenger.Owner.DisplayImage = displayImage;
                m_Messenger.Nameserver.StorageService.UpdateProfile(fileImage, 
"MyPhoto");

This code appears to work with un-provisioned accounts but isn't working with 
my 
provisioned account.

Original comment by scur...@gmail.com on 4 May 2009 at 9:47

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
My program also displays picture only when I use un-provisioned account, but 
when it 
is provisioned it fails to work

Original comment by Flashbo...@gmail.com on 5 May 2009 at 2:55

GoogleCodeExporter commented 9 years ago
Are you sure this is our bug, or, just provisioned account not support display 
picture? Can you provide me a provisioned account for testing? Please do not 
use the 
code in trunk, it's still developing.

Original comment by freezing...@gmail.com on 5 May 2009 at 6:10

GoogleCodeExporter commented 9 years ago
Yeah, I am sure it is in MSNPSHARP. Because provisioned accounts surely support 
Display Picture, and if you try to login with provisioned account in 
amsn-project 
people can see your DP.. I've emailed provisioned account pwd to your email.
This is account which is used for bot so dont change password please.
Thank you!

Original comment by Flashbo...@gmail.com on 5 May 2009 at 12:18

GoogleCodeExporter commented 9 years ago
Yes, you can show the display picture for provisioned accounts using other 
toolkits. 
I know that provisioned accounts that are running bots developed with Windows 
Live 
Agents SDK can set the display pic.

Original comment by scur...@gmail.com on 6 May 2009 at 8:41

GoogleCodeExporter commented 9 years ago
I think this issue should be marked as not fixed yet, 'coz then people may 
think it 
is solved already

Original comment by Flashbo...@gmail.com on 7 May 2009 at 7:29

GoogleCodeExporter commented 9 years ago
I cannot debug with that account, too many people send me messages once I 
login, do 
you have provisioned account that only has a few buddies?

Original comment by freezing...@gmail.com on 9 May 2009 at 11:42

GoogleCodeExporter commented 9 years ago
I had another provisioned account, I gave it to hephappy

Please help, try to fix it, I really need it, or I can't use your SDK at all

Original comment by Flashbo...@gmail.com on 9 May 2009 at 8:50

GoogleCodeExporter commented 9 years ago
I've fixed it, check out the version I committed yesterday.

Original comment by freezing...@gmail.com on 10 May 2009 at 6:19

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago

Original comment by hepha...@gmail.com on 11 May 2009 at 8:16

GoogleCodeExporter commented 9 years ago
Thanks for looking to this issue. But I'm still having trouble with this issue 
on my provisioned accounts. 

Basically here's my code, can you please let me know if I am correctly setting 
the display image. (This code works the the non-provisioned accounts but does 
not work the the provisioned accounts):

// The connection code
m_Messenger = new Messenger();
m_Messenger.Credentials = new Credentials(m_Username, m_Password, 
(MsnProtocol)18);
m_Messenger.Nameserver.AutoSynchronize = false;
AddEventHandlers();
m_Messenger.Connect();

// The On-Signed-In Event Handler
private void OnSignInCompleted(object sender, EventArgs e)
{
        m_Messenger.Nameserver.SetPrivacyMode(PrivacyMode.AllExceptBlocked);
        m_Messenger.Nameserver.SetPresenceStatus(PresenceStatus.Online);

       // Set the user's avatar
       DisplayImage displayImage = new DisplayImage();
       displayImage.Image = Image.FromFile(ConfigurationSettings.AppSettings["ImageFileName"]);;
       m_Messenger.Owner.DisplayImage = displayImage;
       m_Messenger.Nameserver.StorageService.UpdateProfile(fileImage, "MyPhoto");
}

Thanks,
Steve

Original comment by scur...@gmail.com on 12 May 2009 at 4:19

GoogleCodeExporter commented 9 years ago
The code in trunk is not stable, because it uses msnp18.
1) Switch to /branches/MSNPSHARP_25_STABLE
2) Use MsnProtocol.MSNP15
3) DO NOT use StorageService.UpdateProfile(fileImage, "MyPhoto")

For more information:

http://code.google.com/p/msnp-sharp/wiki/MSNPSharp_v25
http://code.google.com/p/msnp-sharp/wiki/Provisioned_Accounts

Original comment by hepha...@gmail.com on 13 May 2009 at 8:14

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Hello
Unfortunately broadcast avatar is still not working.

I am doing as follows:

            messenger.Credentials.Account = "bot@gwaam.com";
            messenger.Credentials.Password = *password*;
            messenger.Owner.CID = (long)-3020064505689571180;
            messenger.Nameserver.BotMode = true;
            messenger.Nameserver.AutoSynchronize = false;

And in Nameserver_SignedIn:

       // Set display picture
       DisplayImage displayImage = new DisplayImage();
       displayImage.Image = Image.FromFile("debug.gif");
       messenger.Owner.DisplayImage = displayImage;

Nobody gets the avatar! What can I do with it?

I am using Msnprotocol.MSNP15 and MSNPSHARP_25_STABLE

Thanks a lot

Original comment by Flashbo...@gmail.com on 29 May 2009 at 8:48