ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Controls, pages and windows / Control functions
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
OpenContextMenu (Function)
In french: OuvreMenuContextuel
AjaxNot available
Warning
From version 28, OpenPopupMenu is kept for backward compatibility. This function has been replaced with OpenContextMenu.
Automatically opens a context menu for the current control, window or page.
Example
// -- Code de clic du bouton BTN_Action
OpenContextMenu(MenuChoixDate)
Syntax
OpenContextMenu([<Context menu name> [, <X> , <Y >]])
<Context menu name>: Optional character string
Name of the context menu that must be opened for the current control.
If this parameter is not specified, the default context menu associated with the control is opened.
Android This parameter is not available. Only the context menu of the current control can be opened.
<X>: Integer (optional)
X-coordinate of the opening position of the context menu. This X-coordinate is expressed in pixels, in relation to the upper-left corner of the window. If <X> and <Y> are not specified, the context menu is opened at mouse position.
AndroidiPhone/iPad This parameter is not available:
  • On the iPhone, the context menu opens according to the iPhone standard: the context menu comes from the bottom of the screen.
  • On iPad, the context menu opens according to the iPad standard: the context menu is displayed next to the field that triggered the menu opening.
  • In Android, the context menu opens in the middle of the screen.
<Y >: Integer (optional)
Y-coordinate of the opening position of the context menu. This Y-coordinate is specified in pixels, in relation to the upper-left corner of the window. If <X> and <Y> are not specified, the context menu is opened at mouse position.
AndroidiPhone/iPad This parameter is not available:
  • On the iPhone, the context menu opens according to the iPhone standard: the context menu comes from the bottom of the screen.
  • On iPad, the context menu opens according to the iPad standard: the context menu is displayed next to the field that triggered the menu opening.
  • In Android, the context menu opens in the middle of the screen.
Remarks
  • This function must be executed the code of a control, window or page.
    This function should not be used in the code for resizing a window.
  • This function is a blocking function until the context menu is closed.
    iPhone/iPad This function is not a locking function in iOS. WEBDEV - Browser code This function is not locking.
  • WINDEV For an MDI child window, it may be interesting to open a context menu defined in the MDI parent window. In this case, <Name of Context menu> must have the following format:
    NameOfWindow.NameOfContextMenu
  • Android This function must be used in one of the processes of the control for which the context menu is to be displayed.
Business / UI classification: UI Code
Component: wd300obj.dll
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 03/27/2025

Send a report | Local help