Looking to build multi-device apps? We have code snippets to get you started

Posted by on in Blogs

With RAD Studio, you can build multi-device applications from a single codebase. If you're just starting with mobile application development using the FireMonkey framework, we have great code snippets to help you get started.

Location Sensor

This code snippet shows you how to use the TLocationSensor component in order to read the GPS location of the device and display it realtime on the form. The snippet also shows you how to display Google Maps in a web browser in order to accurately pinpoint the location of the device on a real map.

Code Sample – Object Pascal
Code Sample – C++

Orientation Sensor

This code snippet shows you how to use the TOrientationSensor component in order to get various compass related information such as three axis tilt, distance and heading, heading relative to magnetic north compensated and uncompensated and heading relative to true north compensated and uncompensated.

Code Sample – Object Pascal
Code Sample – C++

Device Info

This code snippet shows you how to use obtain device information that includes OS version, OS name, and device type.

Code Sample – Object Pascal
Code Sample – C++

 

 

Share Sheet

This snippet shows you how to use standard actions to open the Camera Application on your Android or iOS device to take a photo and display it on your FireMonkey form. Then, with another standard action, you will open the Share Sheet to share your image via email, post to Facebook and Twitter, print via AirPrint and more.

Code Sample – Object Pascal
Code Sample – C++

 

Access all our code snippets and full feature demos here.



About
Gold User, Rank: 5, Points: 558
Senior Product Manager, RAD Studio

Comments

Check out more tips and tricks in this development video: