Please enable JavaScript to view this site.

QPR Knowledge Base 2023.1

  •      
  • Navigation: Developer's Guide > QPR API > The Object Model > QPR Modeling > PGApplication Commands

    FileOpenDialog

    Scroll Prev Top Next More

    Revision history:

    Introduced in QPR 7.4.1

     

    The FileOpenDialog command displays the standard dialog for opening files and returns the selected filename with the full path. Dialog's title, file extension filters and the initial folder can be supplied as parameters.

     

    Synopsis:

     

    PGApplication.FileOpenDialog(Title, DefaultExt, Filter, InitialDir, out Filename)

     

    Parameters:

     

    Title: String. Title displayed for the dialog.

    DefaultExt: String. File extension used by default in the dialog.

    Filter: String. Filter for what file types are shown.

    InitialDir: String. Folder which is shown by default when the dialog is opened.

    out Filename: Variant for storing the returned filename string. The full path is included.

     

    Required Rights:

     

    None.

     

    Return Values:

    Below are listed the return values that this function can return:

     

    RV_SUCCESS

    RV_APPLICATION_QUIT_CALLED

    RV_CANCELLED

     

    Example Procedure:

     

    iResult = PGApplication.FileOpenDialog("FileOpenDialog", "txt", "Text files (*.txt)|*.TXT", "C:\", sFileName)