Skip to main content
System.Device.Location Namespace

The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

The System.Device.Location namespace allows application developers to easily access the computer's location by using a single API. Location information may come from multiple providers, such as GPS, Wi-Fi triangulation, and cell phone tower triangulation. The System.Device.Location classes provide a single API to encapsulate the multiple location providers on a computer and support seamless prioritization and transitioning between them. As a result, application developers who use this API do not need to tailor applications to specific hardware configurations.

System_CAPS_pubclass CivicAddress

Represents a civic address. A civic address can include fields such as street address, postal code, state/province, and country or region.

System_CAPS_pubclass CivicAddressResolver

Provides functionality for resolving a coordinate-based location to a civic address.

System_CAPS_pubclass GeoCoordinate

Represents a geographical location that is determined by latitude and longitude coordinates. May also include altitude, accuracy, speed, and course information.

System_CAPS_pubclass GeoCoordinateWatcher

Supplies location data that is based on latitude and longitude coordinates.

System_CAPS_pubclass GeoPosition

Contains location data of a type specified by the type parameter of the GeoPosition class.

System_CAPS_pubclass GeoPositionChangedEventArgs

Provides data for the PositionChanged event.

System_CAPS_pubclass GeoPositionStatusChangedEventArgs

Contains data for a GeoPositionStatusChanged event.

System_CAPS_pubclass ResolveAddressCompletedEventArgs

Provides data for the ResolveAddressCompleted event.

System_CAPS_pubinterface ICivicAddressResolver

Provides a method that when implemented, resolves a latitude/longitude location to a civic address.

System_CAPS_pubinterface IGeoPositionWatcher

Interface that can be implemented for providing accessing location data and receiving location updates.

System_CAPS_pubenum GeoPositionAccuracy

Specifies the requested accuracy level for the location data that the application uses.

System_CAPS_pubenum GeoPositionPermission

Indicates whether the calling application has permission to access location data.

System_CAPS_pubenum GeoPositionStatus

Indicates the ability of the location provider to provide location updates.

The GeoCoordinateWatcher class supplies location data that is based on latitude and longitude coordinates. The CivicAddressResolver and ICivicAddressResolver types provide the ability to resolve from a coordinate location to a civic address. Additionally, the IGeoPositionWatcher interface can be implemented to extend the types of location data that are supplied.

In Windows 7, all the System.Device.Location classes are fully functional if a location provider is installed and can determine the computer's location. On Windows 7 Starter Edition, the Default Location Provider that can be set in Control Panel is the only location provider that is supported.

Note   In versions of Windows prior to Windows 7, the following conditions apply:

  • All System.Device.Location objects that have constructors can be created, but the property will always have the value Disabled.

  • The location indicated by the property of will always be Unknown.

  • No location events will be raised.

Return to top