New WINDEV Mobile 28 feature!
Help / WLanguage / WLanguage functions / Mobile specific functions / Phone management functions
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
DeepLinkProcedure (Function)
In french: DeepLinkProcédure
Defines the WLanguage procedure executed when the user clicks a deep link. The target URL will have been previously associated with the application during the generation. If necessary, the application will be started automatically.
DeepLinkProcedure (ProcDeepLink)
// ---------------------------------
// Global procedure
// ---------------------------------
PROCEDURE ProcDeepLink(url is URI)
// Gets the product identifier contained in the url
sID is string = ExtractString(url.Query, 2, " = ")
IF WinStatus(WIN_ProductDetails) <> NotFound THEN
OpenMobileWindow(WIN_ProductDetails, sID)
DeepLinkProcedure(<WLanguage procedure>)
<WLanguage procedure>: Procedure name
Name of the WLanguage procedure ("callback") called when the user clicks a deep link with a target URL associated with the application. This procedure must be global. For more details on this procedure, see Parameters of the procedure used by DeepLinkProcedure.
  • It is recommended to call DeepLinkProcedure in the project initialization code, so that the procedure is executed when the application is launched via a link.
  • When the user clicks a deep link:
    • The system checks if the target URL of the link has been associated with an application installed on the device. It also checks if the owner of the application and the domain name corresponding to the URL are the same.
    • If these conditions are not met, the system performs a default action (e.g.: open the link in a browser).
    • If the conditions are met, the following operations are performed:
      • If the application is closed, the system automatically launches the application. The initialization code of the project, classes and sets of procedures will be executed. Then, the procedure passed to DeepLinkProcedure will be executed, if the latter was called in one of the initialization codes. If there are no open windows after the procedure is executed, the first window of the project will be opened.
      • If the application is already running, it will move to the foreground and the procedure passed to DeepLinkProcedure will be executed.
  • You can open windows in the code of the procedure passed to DeepLinkProcedure. It is recommended to check the existence of windows with WinStatus before opening them, in case the user clicks a deep link while the application is running.
  • To determine if the application has been launched via a deep link, use ExeInfo with the exeLaunch constant. If this is the case, the exeDeepLink constant will be returned.
Business / UI classification: Neutral code
Component: wd280android.aar
Minimum version required
  • Version 28
Click [Add] to post a comment

Last update: 03/17/2023

Send a report | Local help