PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN

  • Selecting files
  • Operating mode in Java
  • Former and new directory picker
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Opens a directory picker.
The directory picker is as follows (the appearance may change according to the system used)
Directory picker
Remark: You have the ability to select a local directory or a directory found on a network disk.
// Select a directory
Directory = fSelectDir("C:\Directories", "Select a directory", ...
"Select the directory that will be copied")
Syntax
<Result> = fSelectDir(<Directory selected by default> , <Picker title> [, <Picker comments> [, <Root directory> [, <Options>]]])
<Result>: Character string
  • Path and full name of the selected directory,
  • Empty string ("") if no directory was selected. To get more details on the error, use ErrorInfo with the errMessage constant.
<Directory selected by default>: Character string
Name and full (or relative) path of the directory selected by default. A UNC path can be used. This parameter must end with "\". If this parameter is an empty string (""), no directory will be selected by default.
Windows This parameter can be in Ansi or Unicode format.
<Picker title>: Character string
Text displayed in the title bar of the directory picker.
If this parameter is an empty string (""), the "Find a folder" title will be displayed.
Windows This parameter can be in Ansi or Unicode format.
<Picker comments>: Optional character string
Comments displayed at the top of the directory picker.
Windows This parameter can be in Ansi or Unicode format.
<Root directory>: Optional character string
Name and full path of the "root" directory in the suggested tree structure. A UNC path can be used. If this parameter is an empty string (""), the "Desktop" directory will start the proposed tree structure.
This parameter is used to limit the selection to the directories of a given disk or to the subdirectories of a given directory.
Windows This parameter can be in Ansi or Unicode format.
If this parameter differs from empty string (""), the former directory picker will be used.
<Options>: Optional Integer constant
Allows you to specify:
  • the format of the function result. By default, fSelectDir returns a character string in Ansi format.
  • the style of the directory picker.
fdForbidVirtualFolder<Result> will not contain the virtual directories.
LinuxJava This constant is not available.
fdFormerAspectAllows you to use the former directory picker (old style).
Directory picker
LinuxJava This constant is not available.
fPathUNICODE<Result> will be a Unicode string.
Linux This constant is not available.
Remarks

Selecting files

fSelectDir is used to select a directory. To select a file, use fSelect.
Java

Operating mode in Java

In Java, in Windows, the use of fSelectDir displays a Java window that simulates the aspect and behavior of the Windows directory picker.
To force the use of the Java directory picker, use <wd.prop.sel_rep_defaut> when starting the application and specify one of the following values: oui/o/yes/y/vrai/true.
Example of command line used to start a Java application by forcing the use of the Java directory picker:
java -Dwd.prop.sel_rep_defaut=y -jar MyApplication.jar

In Java, in the other OS (Linux, Mac, ...), the use of fSelectDir displays the Java directory picker.
To force the display of a Java window that simulates the aspect and behavior of the native Windows directory picker, use <wd.prop.sel_rep_windows> when starting the application, and specify one of the following values: oui/o/yes/y/vrai/true.
Example of command line used to start a Java application by forcing the use of the Windows directory picker:
java -Dwd.prop.sel_rep_windows=y -jar MyApplication.jar
WINDEV

Former and new directory picker

From version 23, the new directory picker is used by default.
If the new picker is not supported (the new picker is supported from Windows Vista) or if the <Root> parameter is not empty (the root directory is not supported by the new picker), the former picker is displayed even if the frFormerAspect constant is not specified.
Business / UI classification: UI Code
Component: wd280std.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment