• Skip to main content
  • Skip to header right navigation
  • Skip to site footer
CDP Studio logo

CDP Studio

The no-code and full-code software development tool for distributed control systems and HMI

  • Doc
  • Why CDP
    • Software developers
    • Automation engineers
    • Managers
  • Products
    • Automation Designer
    • HMI Designer
    • CDP Linux
  • Services
  • Use cases
  • Pricing
  • Try CDP

CDP Studio Documentation

  • Framework - External Value Types
  • File Handler
  • 5.1.1

SQLiteValue Handler External Type Path Resolving

File Handler

File Handler

The file handler (ExternalTypes.File) allows CDP properties to reference external files, providing metadata about the file and enabling file operations. This is useful for:

  • Linking configuration files to CDP properties
  • Managing binary or large text content
  • File metadata access (size, content type, modification time)
  • File operations (rename, delete) through property value changes
  • Manipulating the file (i.e., copying, removing, viewing content) via CDP Studio TypeHint="File" delegate

Features:

  • Automatic content type detection
  • File size and metadata reporting
  • File existence validation
  • Safe file operations with error handling
  • File path can contain environment variables and OS-specific slices as described in External Type Path Resolving.

File handler has one configurable property. It can be set globally under the External Type Provider configuration, or per-node using the ExternalType="File;..." model attribute.

Note: The File handler is currently not added to the CDP.ExternalTypesProvider configuration by default. To use it, the handler needs to be added to the CDP.ExternalTypesProvider configuration first (from Resource tree). Also, currently, the File handler supports file manipulation operations (i.e., copying, removing, viewing content) only in offline mode (in CDP Studio Configure Mode). Online mode support for these operations will be added in future releases.

Configuration Properties:

PropertyTypeDefaultDescription
LocationstringPath (relative to application working directory or absolute), where the file will be located. The path can include environment variables and OS-specific slices as described in External Type Path Resolving. Empty means the application working directory will be used.

Metadata Keys Exposed by The File Handler:

KeyDescription
ExternalTypeAlways "File"
NameCurrent filename (if file exists)
ContentTypeMIME content type of the file
LengthFile size in bytes
ErrorError message if file operation failed

Example Usage:

<Attribute Name="simulationmodelfile.fmu" Type="string" ExternalType="File" TypeHint="File"/>

SQLiteValue Handler External Type Path Resolving

The content of this document is confidential information not to be published without the consent of CDP Technologies AS.

CDP Technologies AS, www.cdpstudio.com

Get started with CDP Studio today

Let us help you take your great ideas and turn them into the products your customer will love.

Try CDP Studio for free
Why CDP Studio?

CDP Technologies AS
Hundsværgata 8,
P.O. Box 144
6001 Ålesund, Norway

Tel: +47 990 80 900
E-mail: info@cdptech.com

Company

About CDP

Contact us

Services

Partners

Blog

Developers

Get started

User manuals

Support

Document download

Release notes

My account

Follow CDP

  • LinkedIn
  • YouTube
  • GitHub

© Copyright 2026 CDP Technologies. Privacy and cookie policy.

Return to top