Registering in Chat applicaiton.

Hi

    I am using  the RequestRegister class in the BasicChat.Request namesace.

    While registering I am setting the following properties.

    nickName = "abc";
    userType = UserType.Supervisor;
    personID = "";
    userData = new keyvalueCollection();
    TimeZoneOffset = 20

    I always get the response as user already registered.

     Why is that so. How could I register.

you need to specify the agent id in the place of person id

2 Likes

In some previous versions of PSDK there was automatic registration implemented upon Open method (so when establishing the socket connection). The registration could be performed only once per connection – that is why you are getting such a response from ChatServer.

You need to turn off auto-registration during Open (which is by default I think) – then you will be able to send a specific registration request. For that I believe you need initialize “BasicChatProtocol.UserId” with some dummy string.

Or could specify all these parameters in advance before Open – so you will not need to register separately.

How to turn off auto registration?

1 Like

you need initialize “BasicChatProtocol.UserId” with some dummy string.

1 Like

Actually - there is an attribute “AutoRegister” in BasicChatProtocol object - you could just set it to false.

1 Like