Download File

Download File

Kuika's Download File action allows the user to download a file from a server within the application. This makes it possible for users to save documents or media files to their devices and access them offline. Action is compatible with both web and mobile platforms.

Technical Specifications

  • File Download: It offers the opportunity to download files from the server to devices.
  • Web and Mobile Compatibility: Works seamlessly on all platforms.
  • Base64 Support: Files must be presented in Base64 format.
  • Static and Dynamic Support: The file name and content can be fixed or dynamically defined.
Download File Action Implementation Steps

1. Defining Action in UI Design

  1. Open your project on the Kuika platform.
  2. Switch to the UI Design module.
  3. Add a Button component for file download (like “Download File”).
  1. Select the button and set the appropriate trigger (OnClick, etc.) from the + ADD ACTION menu.
  2. Add the Device > Download File action.

2. Configuring Parameters

  • File Name (String, required):
    • Specifies the name under which the file to be downloaded will be saved on the device.
    • Example: “report2025.pdf”
    • It is usually defined using data sources such as Action Result, Current, Form Component, Screen Input or Fixed and can be bound via Symbol Picker.
  • Data (String, mandatory):
    • Represents the file content in Base64 format.
    • Example: data.base64File
    • It is usually defined using data sources such as Action Result, Current, Form Component, Screen Input or Fixed and can be bound via Symbol Picker.
Usage Scenario: User Downloads a File to their Device

A user wants to download a file (for example, a marketing analysis) to their device by clicking the “Download” button within the application. In this scenario, Kuika's Download File action saves the file directly to the user's device and the user can view the file offline.

Adding a Download File Action to the File Download Area

  1. Log in to the Kuika platform.
  2. Open your project from the Apps screen.
  3. Switch to the UI Design module.
  1. Add a Button (e.g. “Download Marketing File”) component from the left edge.
  2. Select the button and click the + ADD ACTION menu from the Properties panel on the right edge.
  3. Select the OnClick → Device → Download File action.

Configuring the Download File Action

In the action configuration window that opens, define the following fields:

  • File Name: “marketing2025.pdf” (the name under which the file will be saved to the user)
  • Data: data.base64File (file data received from the server and in Base64 format should be linked here)

The file must be provided in Base64 format. If the file is to be downloaded from a URL, that file data must be converted to Base64 and used.

Click the SAVE button to complete the process.

User Experience after File Download

When the user presses the “Download File” button:

  • The specified file is saved in the device's default Downloads folder.
  • The user can open the file offline, share it or store it on their device.
  • Each device can view the file with a different opener according to its system (e.g. PDF reader, gallery, media player).
Download File Action Advanced Customizations
  1. Download with Base64 Format:
    • By entering the file data in Base64 format in the Data parameter, you can ensure that the files are downloaded securely from the server. This is especially useful when you provide dynamic file content.
  2. Download with Static File URL:
    • If the file to be downloaded is static and accessed via URL, you can specify the name of the file with the File Name parameter and download the file using the URL directly.
  3. High Resolution File Download:
    • To optimize the resolution and size of the files to be downloaded, you can perform data compression or formatting operations on the server.
  4. Performance Optimization:
    • If the file size is large, you can use the Quality parameter to reduce the size of high-resolution files in Base64 format to smaller sizes. The Quality parameter both reduces the data transfer time and improves the user experience.

Technical Risks and Controls

  • File Format: Only supported formats should be used.
  • Large Files: Data should be optimized in advance to avoid performance issues.
  • Invalid URL: The file address and data source must be correctly identified.

The Download File action allows users to save documents or media content to their devices. With support for offline access, increased data security and flexible integration options, this action enhances the application experience.

Other Related Content

No items found.

Glossary

No items found.

Alt Başlıklar