RAD Studio, Delphi and C++Builder 10 Seattle Android and iOS Code Samples

This page contains in-depth code samples and code snippets to help you get started building amazing apps with RAD Studio 10 Seattle.

コードサンプル

RAD Studioには、ユーザーインターフェイス設計、デバイスセンサー、サービス、クラウド、モビリティサービス、並列プログラミングなど、強力な製品機能にフォーカスを当てたさまざまなサンプルが用意されています。

クラウド

Samples that show you how to leverage REST APIs using the REST component framework and utilize cloud storage, push notification and more with Backend as a Service providers such as Parse, Kinvey and App42.

C++ Samples
Object Pascal Samples


デバイスセンサーとサービス

Samples that show you how to access location data, display ads in your application, support in-app payments, connect to Bluetooth LE devices and add proximity awareness with beacons.

C++ Samples
Object Pascal Samples


EMS

Samples that show you how to build applications using Enterprise Mobility Services Middleware.

C++ Samples
Object Pascal Samples


Google Glass

Samples that show you how to access Google Glass sensors.

C++ Samples
Object Pascal Samples


メディア

Samples that show you how to access on-device music files for playback and image files for editing and sharing.

C++ Samples
Object Pascal Samples


並列ライブラリ

Samples that show you how to run application tasks in parallel, taking advantage of multiple CPUs.

C++ Samples
Object Pascal Samples


物理エンジン

Samples that show you how to add physics support to your applications.

C++ Samples
Object Pascal Samples


ユーザーインターフェイス

Samples that show you how to add slide-in drawer support, work with list components, access custom keyboards, design setting screens, add tab slide transitions and more.

C++ Samples
Object Pascal Samples


コード例

Learn how to easily add functionality to your app in minutes with feature focused code snippets.

Device Sensors
Accelerometer
Gyroscope
Location
OrientationSensor
Device Services
Device Info
Message Alerts
Notifications (Send/Cancel)
Notifications
  (Set Badge Number)

Phone Dialer
Share Sheet
Touch/Gestures
Interactive Gestures
Tab Sliding

Database Storage
IBLite
SQLite
Native Controls
Custom Picker
Date Picker
Horizontal Scroll
メディア
Access Camera App
Camera Component
Camera Roll
Audio Record and Play
Web Browser
Play Audio File

Accelerometer

加速度センサを使用して、加速度、角加速度、動き、速度に関する情報を取得する方法を示しています。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++


Gyroscope

ジャイロスコープを使用して、AndroidおよびiOS デバイスが傾いたときに 3D 立方体を回転させる方法を示しています。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++


Location

TLocationSensor コンポーネントを使用して、デバイスの GPS 位置情報を読み取り、それをフォームにリアルタイムに表示する方法。また、このコードは、Google マップを使用して実際の地図上のデバイス位置を正確に特定する方法も示しています。
デバイスとシュミレーター用

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Orientation Sensor

TOrientationSensor コンポーネントを使用して、3 軸傾斜、距離と方位、磁北からの方位(補正済みと未補正)、真北からの方位(補正済みと未補正)などのさまざまなコンパス(方位計)関連情報を取得する方法を示しています。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++


Device Info

OS のバージョン、OS の名前、デバイスの種類などのデバイス情報を取得する方法を示しています。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++


Message Alerts

単一ボタンの標準的な情報ボックス形式も、さまざまな確認が可能な複数ボタンの入力ボックス形式も含め、さまざまな警告メッセージをポップアップする方法を示しています。
デバイスとシュミレーター用

Code Sample – Object Pascal
Code Sample – C++


Notifications (Set/Reset Badge Number)

単一ボタンの標準的な情報ボックス形式も、さまざまな確認が可能な複数ボタンの入力ボックス形式も含め、さまざまな警告メッセージをポップアップする方法を示しています。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++


Phone Dialer

PhoneDialer API を使用して、電話をかけたり、キャリア情報を取得する方法を示しています。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++


Share Sheet

標準アクションを使用して、AndroidおよびiOSデバイスのカメラ アプリケーションを開き、写真を撮影し、撮影した画像を取得して FireMonkey フォームに表示する方法。そのあと、別の標準アクションで、共有シートを開いて撮影画像を電子メールやFacebook、Twitterなど他のサービスと共有します。
デバイスのみ

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Interactive Gestures - Image Rotation

This set of code snippets shows you how to rotate an image on an Android or iOS device.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Sliding Tabs

This snippet shows you how to use a TabControl with TabPosition set to tpDots in order to enable scrolling of tab items on Android and iOS devices. The Application has 2 tab items each one containing a different image.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


IBLite Database

This snippet shows you how to populate a listview from an IBLite database using LiveBindings.

To deploy this snippet you need to use the IBLite license, following the instructions that were emailed along with the RAD Studio license (or trial license). For more information on deploying the license file along with the application, you can read: Tutorial: InterBase on iOS and Android
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


SQLite Database

This snippet shows you how to populate a list box from a SQLite database using LiveBindings.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Custom Picker

This code snippet shows you how to use the TComboBox component in order to pick an item from it and display its Text on a label.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Horizontal Scroll

This snippet shows you how to use the THorzScrollBox component in order to scroll through two identical pictures.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Access Camera

This snippet shows you how to use standard actions in order to open the Camera Application on your Android or iOS device, take a picture and retrieve the taken image for displaying on your FireMonkey form.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Camera Component

This code snippet shows you how to manipulate the Camera on your Android or iOS device. The snippet allows you to select either the front facing camera or the back facing camera. Also you can select whether to use the flash (always on or automatic) or not.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Camera Roll

This snippet shows you how to use standard actions in order to open the Photo Library on your Android or iOS device and retrieve an image from the library for displaying on your FireMonkey form.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Send or Cancel Notifications

This code snippets shows you how to use the Notification API in order to send a notification immediately or with a 10 second delay and how to cancel a scheduled notification or all notifications.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Date Picker

This code snippet shows you how to use the TCalendarEdit component in order to pick dates from it and process them to use in your own applications.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Interactive Gestures - Image Zoom

This set of code snippets shows you how to pinch and zoom an image on an Android or iOS device.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Interactive Gestures - Tap and Hold

This set of code snippets shows you how to use tap and hold to display a message.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Audio Recording and Playback

This code snippet shows you how to record some sound via the microphone and then playback using the device speakers or headphones.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Web Browser

This code snippet shows you how to use a WebBrowser component on an Android or iOS device. The application consists of an edit box, a button and the web browser component. Type an address in the edit box and press the "GO" button in order to redirect the browser to your address.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++
Watch Video


Play Audio File

This snippet shows you how to include an audio file for playback in your Android and iOS application.
Designed for device only

Code Sample – Object Pascal
Code Sample – C++


Ready to get started?
Learn more about iOS development with RAD Studio or Android app development with RAD Studio and then you can download a free RAD Studio 30-day license.