FMX.Mobile.LocationDemo Sample (Object Pascal)

From Appmethod Code Examples
Jump to: navigation, search

This is a sample that describes how to use location data in mobile applications, using FireMonkey.


You can find the FireMonkeyMobile LocationDemo sample project at:


This application allows the user to display their location on a map and save it for future use.

How to Use the Sample

  1. Navigate to the location given above and open LocationDemoProject.dproj.
  2. Press F9 or choose Run > Run.


The sample files are LocationDemoUnit, the main form that constitutes the user interface for the FireMonkeyMobile LocationDemo Sample application and LocationDemoProject, the project itself.


FireMonkey TabSlideTransition represents the main window of the sample. It contains the following components:


  • Make sure that the Switch is On and the iOS device has the Location Services On.
  • The sample shows the Latitude and Longitude for the location of the device using the TLocationCoord2D properties and the OnLocationChanged event.
  • TWebBrowser is used to show a map using Google Maps.

See Also