Datalogic .NET SDK

GetGPSPowerStatus (Method)

 

Syntax

 

   public static Boolean GetGPSPowerStatus();

 

 

Class                           : Device

Namespace                : Datalogic.API

Assembly                   : Datalogic.API.DLL

 

 

Description

Get the status of the GPS.

 

 

Parameters Table

 

Type

Parameter

Description

[in]

void

-

-

 

 

 

 

[returns]

Boolean

 

True indicates that the GPS is on, false indicates that the GPS is off.

[on error]

FALSE

 

-

 

 

 

Example

 

         public bool GPSState;

         // ...

        private void btnSetGps_Click(object sender, EventArgs e)

        {

            bool b = false;

 

            GPSState = Device.GetGPSPowerStatus();  // current state

 

            b = Device.SetGPSPowerState(!GPSState); // change state

            if (!b)

            {

                txtGPSStatus.Text = "No GPS avbl";

            }

        }

 

 

 

 

See Also

Example #032.

 

Copyright © Datalogic ADC. All Right Reserved