Choose files

This page is all about letting a user choose a file from their file system. NovaOS lets users select files from the registered app, which has its capabilities as 'file_manager'.

Requesting a file selector window

Here is the method to summon a choose file window with the default files app in NovaOS.

await ntx.olp.useHandler("file_manager", { 
 "opener": "any", 
 "dir": "Downloads/" 
});

This returns the selected file ID once the user has selected it.

Here, we use the OL protocol to launch the application with the data, which has some parameters.

Opener params

Opener param
description
examples

opener

A file type to filter with.

"opener":"json" "opener":"app"

dir

A directory to initialize the choose file window with.

"dir":"Downloads/" "dir":"Apps/"

Last updated

Was this helpful?