Groups | Blog | Home
all groups > dotnet general > february 2004 >

dotnet general : Exception setting SocketOption



Alex Feinman [MVP]
2/28/2004 11:02:21 PM
1) Do not crosspost.
2) According to Windows CE.NET OS documentation the platform itself does not
support SO_RCVTIMEO and SO_SNDTIMEO
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wcewinsk/html/_wcesdk_setsockopt.asp
The actual enumerated values are included for code-level compatibility

[quoted text, click to view]

Milosz - [playseven.com]
2/29/2004 5:59:40 AM
Dim EP As System.Net.IPEndPoint = New System.Net.IPEndPoint(mIP, mPort)


Dim S As Socket = New Socket(EP.AddressFamily, SocketType.Dgram,
ProtocolType.Udp)

S.SetSocketOption(Sockets.SocketOptionLevel.Socket,
Sockets.SocketOptionName.SendTimeout, Me.mTimeOUT)

.......

it crashes with Exception:

"An unknown, invalid, or unsupported option or level was specified in a
getsockopt or setsockopt call"

it seems it does not matter what value is me.mTimeout. i tried 100 and 1000.
I tried also ReceiveTimeOut and with a TCP Socket but it always crashes.

the method is running in an own thread

Somebody knows help ?

THX Milosz



--
-> Milosz Weckowski
www.playseven.com

mailto:mw@playseven.com
ICQ Number: 84867613

Get the enhanced Progressbar and a fine Colorpicker for the Compact Framwork
for free:
http://www.playseven.com/11620/p7_Controls.html

Milosz - [playseven.com]
2/29/2004 8:22:17 AM
thx alex and sorry for the crosspost, no answer was coming in the other
thread..

Does anybody knows a workaround for the timeout problem ?

regards Milosz



"Alex Feinman [MVP]" <public_news@alexfeinman.com> schrieb im Newsbeitrag
news:Ow6f7Hp$DHA.2180@TK2MSFTNGP09.phx.gbl...
[quoted text, click to view]

AddThis Social Bookmark Button