Get access to over 100 FireMonkey cross platform samples for Android, IOS, OSX, Windows, and Linux!

AndroidAppmethodC++BuilderCode SnippetDelphiDemoFiremonkeyIOSOSXWindows

Remotely Control Apps Via App Tethering Or REST In #Delphi XE8 Firemonkey On #Android And #IOS

Delphi XE8 Firemonkey Remote Control App Tethering Android IOSIf you are building enterprise applications with Delphi XE8 Firemonkey you may run into the situation where you need to remotely control your app on a user’s device without being in front of the device. Firemonkey makes it easy to remotely control an app on Android, IOS, OSX, and Windows. I have created some sample source code which will take a screenshot of the current application and send it to a second application via the app tethering components. The second application will allow you to click on the screenshot and execute the click on the first application. Basically it works very similarly to how Remote Desktop works in windows. Obviously this is a very rudimentary version as it sends the entire screen each time and is not optimized to only send only the parts of the screen that have changed. You could also deploy this same type of system using the TRESTClient instead of the app tethering components as the idea is the same. Basically you could have a support section in your app where the user would click a Start Remote Session or Sync button. Your app would begin sending screenshots to the remote server via app tethering or REST. Each time the app sends a screenshot it could also listen for a click. Once a click is received it could execute the click in the local app which would complete the remote control loop. This same type of functionality can be used to build a Firemonkey test harness. The magic happens in the custom FindControlAtPoint function which was developed for the TImageCacheLayout component. This same idea and code should also work in Appmethod and maybe C++Builder. Here is a code snippet of that function:

Download the sample source code for remotely controlling an app in Delphi XE8 Firemonkey on Android and IOS.


Have Delphi Firemonkey questions? Ask and get answers on StackOverflow.

Related posts

FireMonkey 10.4.2 Features Updated iOS 14, Android 11, And macOS 11 Support Plus Hundreds Of Fixes


Ryzen 9 5950x: One Billion Lines Of Delphi Code Compiled In ~5 Minutes On 16 Cores


DelphiCon 2020 FireMonkey Sessions Available Starting November 19


Powerful Commercial Gorilla3D Framework Upgraded For Delphi FireMonkey On Windows And Android

Sign up for our Newsletter and
stay informed

Leave a Reply