AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Funciones WLanguage / Funciones específicas de la Web / Funciones varias de WEBDEV
  • JSMethod handles the aliases of the controls
WINDEV
WindowsLinuxJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac Catalyst
Otros
Procedimientos almacenados
Used to run a JavaScript method on an element found in the current page.
This is an advanced function, requiring a good knowledge of Javascript.
Ejemplo
WEBDEV - Código Navegador
// Page element concerned: a Flash field 
// designated by its alias: "window.document." + sAlias
// JavaScript method: SetVariable
// Parameters: 
// - Customizable flash area: "_root.monScroll.TXT"
// - New text: sText
JSMethod("window.document." + sAlias, "SetVariable", ...
	"_root.myScroll.TXT", sText)
Sintaxis
JSMethod(<Full element name> , <Method> [, <Parameter 1> [... [, <Parameter N>]]])
<Full element name>: Character string
"JavaScript" name of element to use. In most cases, this name starts with "document.". You must use the aliases of controls. For more details, see Remarks.
<Method>: Character string
Method of the element to use. The method name must be indicated directly: it is not possible to use a constructed string.
<Parameter 1>: Optional character string
Parameters of the method.
<Parameter N>: Optional character string
Parameters of the method.
Observaciones

JSMethod handles the aliases of the controls

Javascript is a case-sensitive language: the full name of the element must be case-sensitive: all page and field aliases are capitalized.
To build the name of element name, you must know the control alias. This alias corresponds to the control name in the HTML page. To find out this alias:
  • in the page editor, hover over the element to display the alias used in the tooltip for the field.
  • in the code editor, press Shift + F1.
  • use the Alias property.
When building the full element name, you have the ability to use "_PAGE_" to access the page.
Componente: WDJS.DLL
Versión mínima requerida
  • Versión 9
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 16/01/2025

Señalar un error o enviar una sugerencia | Ayuda local