Property

FolderItemDialog.InitialDirectory


Warning

This item was deprecated in version 2019r2. Please use FolderItemDialog.InitialFolder as a replacement.

Description

Full or relative path to directory whose contents are displayed when the dialog first appears.

Notes

The Filter property controls which files within this directory are visible. On Windows, this defaults to the My Documents directory if no FolderItem is specified.

Sample code

This example illustrates all the labelling properties of a FolderItemDialog.

Dim dlg As OpenDialog
Dim f As FolderItem
dlg = New OpenDialog

#If Not (TargetLinux) then
  dlg.InitialDirectory = SpecialFolder.Documents
#Else //open Home directory on linux
  dlg.InitialDirectory = SpecialFolder.home
#Endif
f = dlg.ShowModal

Compatibility

All project types on all supported operating systems.