centrino,
You can't really extend an existing enumeration (unless you have the
source code).
The best you can do is define the value for the IPinIP protocol as a
constant, or a value in a new enumeration. Then, pass that value to the
Socket constructor, but cast it to the ProtocolType enumeration type. When
casting an int or enumeration to another enumeration type, there is no check
to make sure the value is part of the enumeration.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"centrino" <ce******@discussions.microsoft.com> wrote in message
news:18**********************************@microsof t.com...
hi,
I want to extend System.Net.Sockets.ProtocolType to IPinIP protocol, how
can
i do that.
Do i have to make new class or enum stuct for this type ?
regards