Windows Dev Center

Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

ConnectionProfile.GetLocalUsage(DateTime, DateTime) | getLocalUsage(DateTime, DateTime) method

[GetLocalUsage may be altered or unavailable for releases after Windows 8.1. Instead, use GetNetworkUsageAsync]

Gets the estimated data usage for a connection during over a specific period of time.

Syntax


var dataUsage = connectionProfile.getLocalUsage(StartTime, EndTime);

Parameters

StartTime

Type: Date [JavaScript] | System.DateTimeOffset [.NET] | Windows::Foundation::DateTime [C++]

The start date/time for the usage data request.

EndTime

Type: Date [JavaScript] | System.DateTimeOffset [.NET] | Windows::Foundation::DateTime [C++]

The end date/time for the usage data request.

Return value

Type: DataUsage

The requested local data usage information.

Remarks

For an example of how this method is used, see How to retrieve connection usage data for a specific period of time.

Requirements (Windows 10 device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.Networking.Connectivity
Windows::Networking::Connectivity [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

None supported

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Networking.Connectivity
Windows::Networking::Connectivity [C++]

Metadata

Windows.winmd

Attributes

[Deprecated()]

See also

ConnectionProfile
GetLocalUsage(DateTime, DateTime, RoamingStates)

 

 

Show:
© 2015 Microsoft