PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN
This content has been translated automatically. Click here to view the French version.
  • Disabling options and bar of edit mode
  • Deleting the Edit mode for the end user (via the AAF)
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 or closes the "Edit" mode of Dashboard control.
Versions 22 and later
iPhone/iPad This function is now available for iPhone/iPad applications.
Android This function is now available for Android applications.
New in version 22
iPhone/iPad This function is now available for iPhone/iPad applications.
Android This function is now available for Android applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Android This function is now available for Android applications.
Example
Android
// Si le champ Tableau de bord est déjà en mode édition, avertit l'utilisateur
IF DashMode(TDB_TableauDeBord) <> dashNoModif THEN
Error("Le tableau de bord est déjà en mode édition")
RETURN
END
 
nOption is int
 
// Définit l'option d'édition
IF INT_OptionsEdition[1] THEN nOption += dashMove
IF INT_OptionsEdition[2] THEN nOption += dashResize
IF INT_OptionsEdition[3] THEN nOption += dashDelete
 
// Vérifie qu'une option au moins soit cochée
IF nOption = 0 THEN
Error("Vous devez cocher au moins une option d'édition")
SetFocusAndReturnToUserInput(INT_OptionsEdition)
END
 
// Modifie le mode d'édition
DashMode(TDB_TableauDeBord, nOption)
Android
// Désactiver la suppression des widgets
// mais pas leur déplacement ou leur redimensionnement:
DashMode(TDB_SansNom1, dashMove + dashResize)
// Attention, pour ne pas afficher du tout la barre d'outils,
// il faut utiliser la fonction DésactiveFAA (ou FAADésactive) avec la constante faaTdbModeEdition.
Syntax

Modifying the mode of Dashboard control Hide the details

DashMode(<Dashboard control> , <Mode>)
<Dashboard control>: Control name
Name of the Dashboard control to be used.
<Mode>: Integer constant (or combination of constants)
Edit options available for the user:
dashMoveSwitch to edit mode: the user can move the widgets in the Dashboard control.
dashResizeSwitch to edit mode: the user can resize the widgets in the Dashboard control.
dashNoModifClose the edit mode: the user cannot modify the widgets in the Dashboard control.
This constant cannot be combined with the other constants.
dashDeleteSwitch to edit mode: the user can hide the widgets in the Dashboard control.

Finding out the current mode of Dashboard control Hide the details

<Result> = DashMode(<Dashboard control>)
<Result>: Integer constant
Current edit mode of Dashboard control:
dashMoveEdit mode: the user can move the widgets in the Dashboard control.
dashResizeEdit mode: the user can resize the widgets in the Dashboard control.
dashNoModifStandard mode: the user cannot modify the widgets in the Dashboard control.
dashDeleteEdit mode: the user can hide the widgets in the Dashboard control.
<Dashboard control>: Control name
Name of the Dashboard control to be used.
Remarks
AndroidiPhone/iPadMac Catalyst

Disabling options and bar of edit mode

DashMode is used to disable some features of the Dashboard control. Deleting these features can have consequences on the bar of edit mode. Thus, if deleting widgets is forbidden, the trash button is not displayed in the toolbar.
Remark: To entirely disable the toolbar display on the Dashboard control, use AAFDisable associated with the aafDashEditMode constant.

Deleting the Edit mode for the end user (via the AAF)

DashMode is used to switch to edit mode through programming.
To remove the possibility for the user to switch to edit mode (via the popup menu or long click), use the AAFDisable function with the aafDashEditModeconstant.
Related Examples:
WD Dashboard Training (WINDEV): WD Dashboard
[ + ] The "WD Dashboard" example is an educational example for using the Dashboard control.
This example explains how to:
- handle the control in "edit" mode,
- save/load a configuration,
- configure the control (initial configuration, addition/deletion of widgets, ...),
- refresh a widget,
- etc.
WW_Dashboard Training (WEBDEV): WW_Dashboard
[ + ] The "WD Dashboard" example is an educational example for using the Dashboard control.
This example explains how to:
- handle the control in "edit" mode,
- save/load a configuration,
- configure the control (initial configuration, addition/deletion of widgets, ...),
- refresh a widget.
Component: wd270obj.dll
Minimum version required
  • Version 19
This page is also available for…
Comments
Click [Add] to post a comment