472,331 Members | 1,786 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,331 software developers and data experts.

Error when constructing TcpClient : Error ...the system lacked insufficient buffer space or because a queue was full

i get this error if i write this :

using System.Net.Sockets;

....

....
TcpClient tcp;
tcp=new TcpClient();

An unhandled exception of type 'System.Net.Sockets.SocketException' occurred
in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full
Any hints ?
Nov 15 '05 #1
4 6738

"Sagaert Johan" <RE*******************@hotmail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
i get this error if i write this :

using System.Net.Sockets;

...

...
TcpClient tcp;
tcp=new TcpClient();

An unhandled exception of type 'System.Net.Sockets.SocketException' occurred in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full
Any hints ?

When creating a simple Socket i got something similar , i guess something is
wrong on my system

Socket sok;

sok=new
Socket(System.Net.Sockets.AddressFamily.InterNetwo rk,System.Net.Sockets.Sock
etType.Stream,System.Net.Sockets.ProtocolType.Tcp) ;

Yields this runtime error

An unhandled exception of type 'System.Net.Sockets.SocketException' occurred
in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full

when i hit continue, this one pops up

An unhandled exception of type 'System.TypeInitializationException' occurred
in WindowsApplication4.exe

Additional information: The type initializer for "System.Net.Sockets.Socket"
threw an exception.

Nov 15 '05 #2

"Sagaert Johan" <RE*******************@hotmail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
i get this error if i write this :

using System.Net.Sockets;

...

...
TcpClient tcp;
tcp=new TcpClient();

An unhandled exception of type 'System.Net.Sockets.SocketException' occurred in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full
Any hints ?

When creating a simple Socket i got something similar , i guess something is
wrong on my system

Socket sok;

sok=new
Socket(System.Net.Sockets.AddressFamily.InterNetwo rk,System.Net.Sockets.Sock
etType.Stream,System.Net.Sockets.ProtocolType.Tcp) ;

Yields this runtime error

An unhandled exception of type 'System.Net.Sockets.SocketException' occurred
in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full

when i hit continue, this one pops up

An unhandled exception of type 'System.TypeInitializationException' occurred
in WindowsApplication4.exe

Additional information: The type initializer for "System.Net.Sockets.Socket"
threw an exception.

Nov 15 '05 #3
"Sagaert Johan" <RE*******************@hotmail.com> wrote in message news:<OG**************@TK2MSFTNGP12.phx.gbl>...
"Sagaert Johan" <RE*******************@hotmail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
i get this error if i write this :

using System.Net.Sockets;

...

...
TcpClient tcp;
tcp=new TcpClient();

An unhandled exception of type 'System.Net.Sockets.SocketException'

occurred
in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full
Any hints ?

Sagaert -

Have you checked to make sure the program has the proper security
settings to allow access to Sockets? Be careful when running network
programs from a shared network drive, or from accounts that do not
have the appropriate system priviledges. Hope this helps shed some
light on your problem.

Rich Blum - Author
"C# Network Programming" (Sybex)
http://www.sybex.com/sybexbooks.nsf/Booklist/4176
"Network Performance Open Source Toolkit" (Wiley)
http://www.wiley.com/WileyCDA/WileyT...471433012.html
Nov 15 '05 #4
"Sagaert Johan" <RE*******************@hotmail.com> wrote in message news:<OG**************@TK2MSFTNGP12.phx.gbl>...
"Sagaert Johan" <RE*******************@hotmail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
i get this error if i write this :

using System.Net.Sockets;

...

...
TcpClient tcp;
tcp=new TcpClient();

An unhandled exception of type 'System.Net.Sockets.SocketException'

occurred
in system.dll

Additional information: An operation on a socket could not be performed
because the system lacked sufficient buffer space or because a queue was
full
Any hints ?

Sagaert -

Have you checked to make sure the program has the proper security
settings to allow access to Sockets? Be careful when running network
programs from a shared network drive, or from accounts that do not
have the appropriate system priviledges. Hope this helps shed some
light on your problem.

Rich Blum - Author
"C# Network Programming" (Sybex)
http://www.sybex.com/sybexbooks.nsf/Booklist/4176
"Network Performance Open Source Toolkit" (Wiley)
http://www.wiley.com/WileyCDA/WileyT...471433012.html
Nov 15 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: MSNews | last post by:
I get the following exception when calling Dns.GetHostName (from C#): An unhandled exception of type 'System.Net.Sockets.SocketException' occurred...
0
by: Jinsu Park | last post by:
I am working on a form-based application and this application has been running (in debug mode) fine so far. Now when I run this in debug mode, I am...
1
by: paulbubach | last post by:
Hi @all, we have the following problem. We have developed an application with the Visual Studio.Net 2002 and the project runs on it. But now we...
0
by: Sagaert Johan | last post by:
i get this error if i write this : using System.Net.Sockets; .... .... TcpClient tcp; tcp=new TcpClient();
0
by: mvenkataraman | last post by:
Hello, We had been using a Web Application named Ultimate Survey 2.0 by www.prezzatech.com for a while and deployed it in Windows Server 2003. We...
0
by: mvenkataraman | last post by:
Hello, We had been using Ultimate Survey 2.0 by www.prezzatech.com for a while and deployed it in Windows Server 2003. This application is written...
2
by: Steve Lowe | last post by:
Hi, I have a VB.Net 2003 program that uses Indy to check if there are any messages waiting on a POP mail server. The program has been running...
1
by: Fresno Bob | last post by:
Hi I have a web service that calls the Site Server 2008 web service returning an error 'An operation on a socket could not be performed because the...
4
by: aMerkert17 | last post by:
I'm trying to write a Silverlight client that communicates with a server on a virtual machine over sockets. The service works as expected for several...
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: teenabhardwaj | last post by:
How would one discover a valid source for learning news, comfort, and help for engineering designs? Covering through piles of books takes a lot of...
0
by: CD Tom | last post by:
This happens in runtime 2013 and 2016. When a report is run and then closed a toolbar shows up and the only way to get it to go away is to right...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.