No progress é possível usar o tratamento SYSTEM-DIALOG GET-FILE para chamar uma janela de busca de arquivo.
Sintaxe:
SYSTEM-DIALOG GET-FILE character-field [ FILTERS name filespec [ , name filespec ] ... [ INITIAL-FILTER filter-num ] ] [ ASK-OVERWRITE ] [ CREATE-TEST-FILE ] [ DEFAULT-EXTENSION extension-string ] [ INITIAL-DIR directory-string ] [ MUST-EXIST ] [ RETURN-TO-START-DIR ] [ SAVE-AS ] [ TITLE title-string ] [ USE-FILENAME ] [ UPDATE logical-variable ] [ IN WINDOW window ]
Ex:
define variable cFile as character no-undo. define variable logOk as logical no-undo. SYSTEM-DIALOG GET-FILE cFile TITLE "Selecione o arquivo" FILTERS "Arquivos Texto (*.txt)" "*.txt", "Arquivos Excel (*.xls, *.xlsx)" "*.xls", , "Aequivos World (*.doc, *.docx)" "*.doc, *.docx" INITIAL-DIR "C:\" MUST-EXIST USE-FILENAME UPDATE logOK. if logOK = yes then MESSAGE cFile VIEW-AS ALERT-BOX. else MESSAGE "Cancelado" VIEW-AS ALERT-BOX.