C# The attempted operation is not supported for the type of object referenced
问题 I got this error when I tried to parse an IP address that was in string form. I was using a public dns ip address (4.2.2.2) while testing this (using the System.Net's IPAddress.Parse method). It does the parsing correctly and returns an IPAddress object. However, if I try to access the ScopeId property of this object, a SocketException is thrown with the message given in the title. I really am not able to figure out whats the problem here. When I checked the documentation of IPAddress.ScopeId