Used to control how System.Net.NetworkInformation.Ping data packets are transmitted.
See Also: PingOptions Members
The System.Net.NetworkInformation.PingOptions class provides the PingOptions.Ttl and PingOptions.DontFragment properties to control how Internet Control Message Protocol (ICMP) echo request packets are transmitted.
The PingOptions.Ttl property specifies the Time to Live for packets sent by the System.Net.NetworkInformation.Ping class. This value indicates the number of routing nodes that can forward a System.Net.NetworkInformation.Ping packet before it is discarded. Setting this option is useful if you want to test the number of forwards, also known as hops, are required to send a packet from a source computer to a destination computer.
The PingOptions.DontFragment property controls whether data sent to a remote host can be divided into multiple packets. This option is useful if you want to test the maximum transmission unit (MTU) of the routers and gateways used to transmit the packet.
Instances of the System.Net.NetworkInformation.PingOptions class are passed to the erload:System.Net.NetworkInformation.Ping.Send and erload:System.Net.NetworkInformation.Ping.SendAsync methods, and the System.Net.NetworkInformation.PingReply class returns instances of System.Net.NetworkInformation.PingOptions via the PingReply.Options property.
For a list of initial property values for an instance of System.Net.NetworkInformation.PingOptions, see the erload:System.Net.NetworkInformation.PingOptions.#ctor constructor.