How to Get Device Lat Long in Flutter

I need Device current latitude and longitude in flutter how to get it ?


Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.


Refer to below link, which provides some insights about Flutter:

Below would fetch that information:

if (_currentPosition != null) Text( “LAT: ${_currentPosition.latitude}, LNG: ${_currentPosition.longitude}”), FlatButton( child: Text(“Get location”), onPressed: () { _getCurrentLocation();

Hope this helps!

Cheers, Sri Charan