# Thread: [TS3QueryLib.Net] .Net Query Port Library

1. -= TeamSpeak User =-
Join Date
August 2010
Location
Prague, CZ
Posts
13
Thank you!

2. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118

## New Version 0.29.22.0

Due to the recent beta28 and beta29 release I've created a new release of the library. You can download it here:

http://ts3querylib.codeplex.com/releases/view/53437

Changes:
- Fixed problem that was raised by the new greeting of server beta 29.
- Renamed methods of class "QueryRunner": (beta 29 change)
-> GetTokenList --> GetPrivilegeKeyList
-> AddToken --> AddPrivilegeKey
-> DeleteToken --> DeletePrivilegeKey
-> UseToken --> UsePrivilegeKey
- Changed calculation of property "Uptime" of class "HostInfoResponse" (beta 29 change)
- Added overload (new parameter: includeCountry) to method: GetClientList of class QueryRunner. (Beta 28 change)
- Added property "ClientCountry" to class "ClientListEntry" (beta 28 change)

IMPORTANT: When you're using version beta 29 this release is mandatory!!

Please report bugs and feel free to criticize me
SCO

3. -= TeamSpeak Addict =-
Join Date
December 2009
Posts
244
After updating, i saw that the .dll version are still shown as 0.29.21.0 and not 0.29.22.0 :/

4. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118
The version number in the assembly is wrong. But the changes are included.

5. -= TeamSpeak Addict =-
Join Date
December 2009
Posts
244
When i tried the new lib i got the same error as i pm'ed you.
After using the source code to compile the dll's i got the same message error but in a different place (in the lib if i can say like this). See new PM

(Dunno why the errors don't show at the same place using the pre compiled dll or the newly compiled one)

6. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118

## New Version 0.29.23.0

Due to a bug found by TotoIsBack I've released a new version. This bug could have hit many users. Here is the release:

http://ts3querylib.codeplex.com/releases/view/53462

Changes:
- Changed "ServerMachineId" property of classes "ServerListItem", "ServerInfoResponse" and "VirtualServerModification" from uint? to string.
- Fixed a bug in AsyncTcpDispatcher that may occur when disconnecting and reconnecting using the same instance.
- Removed debug tracing in SyncTcpDispatcher

Please report bugs and feel free to criticize me
SCO

7. -= TeamSpeak User =-
Join Date
October 2010
Location
Germany
Posts
13
I'm using your Lib for quite some while now and I really appreciate your work. You've done a good job there.

But I got a Question now.

When I try to connect to the TS3 Server it works most of the Time, but every now and then I get a Socket Error. To be precise protocol not supported.

It's not really helpful for me.
Do you have any idea why I get this Error every now and then? (Works for quite some time and then I get the error for 5 mins)

EDIT:
I noticed, that it is similar to the Error before you released the version 29.22 and I used 29.21 and Beta 29.
But I'm sure I'm using 29.23 and Beta 29 Server.

EDIT2:
I tried it with 2 Server now. One Local one the same machine as my script. The other Server is on a dedicated Server.
When I use my Script on the Local machine I never got this error.
When I use my Script on the Dedicated Server I get this error the 2. Time I use my script.
But it's also taking way longer then on then local server.
Maybe it is because the query can't log out fast enough?
Last edited by Enril1112; October 6th, 2010 at 05:28 PM.

8. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118
Which Dispatcher are you using? Async or Sync?

9. -= TeamSpeak User =-
Join Date
October 2010
Location
Germany
Posts
13
Sync one.

All I do with it is generating a new token.

This is the Part where I get the error. (The login to be precise)

Line 29: if (TcpDispatcher.IsConnected)
Line 30: TcpDispatcher.Disconnect();
Line 31: TcpDispatcher.Connect();
Line 32: queryRunner = new QueryRunner(TcpDispatcher);
Line 33: queryRunner.Login(login, password);
Last edited by Enril1112; October 6th, 2010 at 09:03 PM.

10. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118
Hello,

I've added some tracing when this error occurs. Can you get the latest version from the project page, compile it and use it?

Please provide me the trace that's written when the error occurs.

You can get the trace this way:

Code:
StringBuilder traceBuilder = new StringBuilder();
StringWriter traceWriter = new StringWriter(traceBuilder);
TextWriterTraceListener traceListener = new TextWriterTraceListener(traceWriter);
System.Diagnostics.Trace.Listeners.Add(traceListener);

...
// your code here
...

string traceText = traceBuilder.ToString();
Please give me the traceText.

If you want I can send you the new assembly but i need your email.

Bye
SCO

11. -= TeamSpeak User =-
Join Date
October 2010
Location
Germany
Posts
13
Thanks for all your help.
With your trace help I found the error myself.
He throw that error 'cause the greeting was to long.
It was:
Greeting: TS3 Greeting: TS3 Welcome to the TeamSpeak 3 ServerQuery interface, type "help" for a list of commands and "help " for information on a specific command. error id=3329 msg=connection\sfailed,\syou\sare\sbanned extra_msg=you\smay\sretry\sin\s393\sseconds

Have to speak to the person who set up the server
Just bans my when I use the Server Query to much.

Thanks for you help

12. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118
That you are banned is a problem of too restrictive anti flood settings.. that the protocol exception occurs is a problem of the synctcpdispatcher in this case.

To fix this a have to change a lot of code. I'll hopefully do this within the next days.

13. -= TeamSpeak User =-
Join Date
October 2010
Location
Germany
Posts
13
But the error only occurs 'cause I got banned.

So if you want you can change it so you get a message that you got banned.

But it's not neccesary. Works fine like this.

14. -= TeamSpeak Addict =-
Join Date
December 2009
Location
Germany
Posts
118
I have just added a check whether the client is banned after connecting.
An InvalidOperationExceptions is thrown for this case with more details on it.

SCO

15. -= TeamSpeak User =-
Join Date
October 2010
Location
Germany
Posts
13
I got some problems using the Events you made.
Any quick advise?

My plan is to get a list of ppl who were in a specific channel in a set period of time. (ie You click a button, click it again and you get a list of ppl who were in the channel you specified in the time between the 2 clicks)

#### Thread Information

##### Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•