Kartones


Hi

I'm testing an activity and having some problems because I don't know how to detect whenever the client doesn't supports activities (old Messengers, web messenger, PocketPC Messenger...).

Looking at WLMActivityUtilities.pkg I found this procedure:

procedure MSNSLPUserCanNotOpenP4Window()

Ií»ve tried overriding it to show a message to the user and log an exception (just to test it before doing actual cancellation code):

procedure overrides MSNSLPUserCanNotOpenP4Window()

- Your client doesn't support activities.
call inherited MSNSLPUserCanNotOpenP4Window()

Ií»ve tried connecting from MSN Web Messenger (MS oficial web-based client) and the problem is that the procedure is never called/triggered.
The Agent says the words previous to send the invitation, but nothing else appears on the conversation window, and nothing is logged (I do logging on XML files too, for easier debugging).

How can I detect if the user cannot open/use activities






Re: Detecting if the client doesn't supports Activities

Kartones


More info after some tests:
  • With very old clients (Windows Messenger included in Windows XP) the function is called properly.
  • With MSN Web Messenger, PocketPC/Windows Mobile 6.0 Live Messenger and the WLAs SDK's Query Window, the procedure is not called.
Maybe it just looks at the MSNP version There ins't any way of checking if the client supports activities






Re: Detecting if the client doesn't supports Activities

BrittCoop - MSFT

You will want to determine that the user can open Activity Windows *and* the user is not on mobile. You will do the folloowing check and then call the MSNSLPUserCanNotOpenP4Window proc.

if (CLIENTID & 512) != 0 || (CLIENTID & 1) != 0 || (CLIENTID & 4026531840) < 1073741824

call MSNSLPUserCanNotOpenP4Window()


DEFINITIONS:

(CLIENTID & 512) != 0 -- checks if the user is on the web

(CLIENTID & 1) != 0 -- checks if the user is on mobile

(CLIENTID & 4026531840) < 1073741824 -- checks if the user is on an old version of Messenger









Re: Detecting if the client doesn't supports Activities

Kartones

Many thanks Brit, I've tested it and now works perfectly!

Regards,





Re: Detecting if the client doesn't supports Activities

Riaanvs

Hi Britt

I'm not sure I follow with (CLIENTID .. etc)

Where is CLIENTID defined - is it a variable

I've looked in my WLMActivityUtilities package and there's nothing like that there.

All I'm trying to achieve is to detect if the user is using WLM on a mobile device.

Thanks
Riaan






Re: Detecting if the client doesn't supports Activities

Tom Ragle - MSFT

This is a reference to the number identifying the version of the Messenger client, which is exposed here in the SYS variable: SYS.History[0].Query.ExtraInfo.ClientId

CLIENTID is example verbiage -- it could be a parameter or routine variable for a function that returns the ID number, for example.






Re: Detecting if the client doesn't supports Activities

Riaanvs

HI Tom

On SE 3.4 I'm not sure I have access to SYS.History[0].Query.ExtraInfo.ClientId

Do you know if there's something similar on the previous plaforms

Riaan






Re: Detecting if the client doesn't supports Activities

Tom Ragle - MSFT

Can you print out the SYS.History variable from a session






Re: Detecting if the client doesn't supports Activities

Kartones

Riaanvs wrote:
On SE 3.4 I'm not sure I have access to SYS.History[0].Query.ExtraInfo.ClientId

Do you know if there's something similar on the previous plaforms

Riaanvs, I've got the same problem with the latest build (4.3.0.1321), the first time I call that function (when user arrives in a new conversation window) it gives an error saying that doesn't exists.

Rolling back to 4.3.0.1319 version it works fine (as it did all the time). At the moment I'm sticking to the .1319 build until I have time to check why it can be happening.

Hope that helps you.





Re: Detecting if the client doesn't supports Activities

Gruia Pitigoi-Aron - MSFT

This is not doable in an earlier platform (3.4).

Thank you,

Gruia