PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Opens a system window to select a resource coming:
  • from the device file system,
  • from the Cloud (Google Drive, Microsoft OneDrive, etc.)
  • from one of the content managers installed on the device.
Versions 25 and later
iPhone/iPad This function is now available for iPhone/iPad applications.
New in version 25
iPhone/iPad This function is now available for iPhone/iPad applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Example
AndroidAndroid Widget
// Open the system window to select an image or a pdf
UriResource is URI = URISelect(uriImage + TAB + " application/pdf ")
IF NOT ErrorOccurred THEN
// Displays the name of the selected resource
Info(URIGetInfo(UriResource, uriInfoName))
END
Versions 25 and later
iPhone/iPad
// Open the system window to select an image or a pdf
URISelect(MyProcURISelect, uriImage + TAB + " application/pdf ")
 
INTERNAL PROCEDURE MyProcURISelect(Success is boolean, Result1 is URI)
IF Success = True THEN
// Displays the name of the selected resource
ToastDisplay(URIGetInfo(Result1, uriInfoName))
END
END
New in version 25
iPhone/iPad
// Open the system window to select an image or a pdf
URISelect(MyProcURISelect, uriImage + TAB + " application/pdf ")
 
INTERNAL PROCEDURE MyProcURISelect(Success is boolean, Result1 is URI)
IF Success = True THEN
// Displays the name of the selected resource
ToastDisplay(URIGetInfo(Result1, uriInfoName))
END
END
iPhone/iPad
// Open the system window to select an image or a pdf
URISelect(MyProcURISelect, uriImage + TAB + " application/pdf ")
 
INTERNAL PROCEDURE MyProcURISelect(Success is boolean, Result1 is URI)
IF Success = True THEN
// Displays the name of the selected resource
ToastDisplay(URIGetInfo(Result1, uriInfoName))
END
END
Syntax
AndroidAndroid Widget
<Result> = URISelect([<MIME types>])
<Result>: URI variable
  • URI that corresponds to the selected resource.
  • The ErrorOccurred variable is set to True if an error occurs. To find out the error details, use ErrorInfo.
<MIME types>: Optional character string or constant
  • List of MIME types of selectable files, separated by TAB.
  • Specific constants:
    uriAudioAllows all types of audio files.
    uriImageAllows all types of image files.
    uriVideoAllows all types of video files.

If a specified MIME type is not known by the system, it will be ignored.
If this parameter is not specified, all files will be selectable.
On Android, files that do not match the specified MIME types will still be visible but the user will not be able to select them.
Versions 25 and later
iPhone/iPad
URISelect(<WLanguage procedure> [, <MIME types>])
<WLanguage procedure>: Procedure name
Name of WLanguage procedure ("callback" procedure) that will be called for each listed file. This procedure is called when the user closes the URI selection window. This procedure has the following format:
<Procedure name>(<Success> is boolean, <Result> is URI)
where:
  • <Success< is boolean, True if the resource has been selected, False in case of error. To find out the error details, use ErrorInfo.
  • If <Success< is set to True, <Result> is a URI variable corresponding to the selected resource.
<MIME types>: Optional character string or constant
  • List of MIME types of selectable files, separated by TAB.
  • Specific constants:
    uriAudioAllows all types of audio files.
    uriImageAllows all types of image files.
    uriVideoAllows all types of video files.

If a specified MIME type is not known by the system, it will be ignored.
If this parameter is not specified, all files will be selectable.
On Android, files that do not match the specified MIME types will still be visible but the user will not be able to select them.
New in version 25
iPhone/iPad
URISelect(<WLanguage procedure> [, <MIME types>])
<WLanguage procedure>: Procedure name
Name of WLanguage procedure ("callback" procedure) that will be called for each listed file. This procedure is called when the user closes the URI selection window. This procedure has the following format:
<Procedure name>(<Success> is boolean, <Result> is URI)
where:
  • <Success< is boolean, True if the resource has been selected, False in case of error. To find out the error details, use ErrorInfo.
  • If <Success< is set to True, <Result> is a URI variable corresponding to the selected resource.
<MIME types>: Optional character string or constant
  • List of MIME types of selectable files, separated by TAB.
  • Specific constants:
    uriAudioAllows all types of audio files.
    uriImageAllows all types of image files.
    uriVideoAllows all types of video files.

If a specified MIME type is not known by the system, it will be ignored.
If this parameter is not specified, all files will be selectable.
On Android, files that do not match the specified MIME types will still be visible but the user will not be able to select them.
iPhone/iPad
URISelect(<WLanguage procedure> [, <MIME types>])
<WLanguage procedure>: Procedure name
Name of WLanguage procedure ("callback" procedure) that will be called for each listed file. This procedure is called when the user closes the URI selection window. This procedure has the following format:
<Procedure name>(<Success> is boolean, <Result> is URI)
where:
  • <Success< is boolean, True if the resource has been selected, False in case of error. To find out the error details, use ErrorInfo.
  • If <Success< is set to True, <Result> is a URI variable corresponding to the selected resource.
<MIME types>: Optional character string or constant
  • List of MIME types of selectable files, separated by TAB.
  • Specific constants:
    uriAudioAllows all types of audio files.
    uriImageAllows all types of image files.
    uriVideoAllows all types of video files.

If a specified MIME type is not known by the system, it will be ignored.
If this parameter is not specified, all files will be selectable.
On Android, files that do not match the specified MIME types will still be visible but the user will not be able to select them.
Remarks
  • To manage the URI returned by URISelect, use the URIxxx functions.
  • AndroidAndroid Widget On Android, the URI returned by URISelect is valid only until the next restart of the device.
  • To retrieve additional information (name, size, MIME type) on the selected resource, use URIGetInfo.
  • AndroidAndroid Widget URISelect is only available on devices running Android 4.4 or later(api level 19).
    A fatal error occurs if the function is used with an earlier system version.
    To know the Android version on which the application is running, use SysAndroidVersion.
Business / GUI classification : Business Logic
Component : wd250android.jar
Minimum version required
  • Version 24
Comments
Click [Add] to post a comment