Yuari
Documentation
Docs/Dialogs/openfiledialog

openfiledialog

Shows an open-file dialog.

Syntax

openfiledialog(filter?: string, title?: string) -> nil

Parameters

ParameterTypeDescription
filter?stringThe filter value used by the call.
title?stringThe title value used by the call.

Returns

TypeDescription
nilThis function does not return a value.

Description

openfiledialog is part of the Dialogs library. Dialog helpers call native Windows pickers. The call blocks until the user chooses a path or cancels.

The operation is performed immediately using the arguments supplied at the call site.

Example

local file = openfiledialog("Text files (*.txt)|*.txt|All files (*.*)|*.*", "Choose a file")
print(file)

Notes

  • The dialog blocks until the user selects a path or cancels.