string ReadFileDataBase64(string, int64, int)

Reads bytes from a file as a base-64 encoded string

Security

Trust Level Required: Full Trust

Parameters

Name Description
filePath string
The path of the file.
startPosition int64
The position to start reading the file from. This number must be less than the size of the file in bytes.
byteLength int
The number bytes to read from the file.

Return

The file bytes encoded as a base-64 string.

Remarks

The kiosk user must have sufficient permissions to perform any file IO operation that performs a read or write operation on the current disk.

Examples


var sampleFile = KioApp.DoUrlSubstitution('$$KIO_USERDATA$$') + 'sampleFile.txt';
var sampleFileInfo = KioFileIO.GetFileDetails(sampleFile);
console.log(KioFileIO.ReadFileDataBase64(sampleFile, 0, (JSON.parse(sampleFileInfo).Length)));
    

Requirements

KioWare for Windows version 8.3 or greater.