|
|
|
|
|
- Differentiating a code run in an component from a code run in a project (WINDEV or WEBDEV)
- Component test mode
- Function availability
InComponentMode (Function) In french: EnModeComposant Indicates whether the code is run: - from a WINDEV application, a WEBDEV site or a PHP page.
- from a component.
In a project used both to create an executable or a site and to create a component, this function is used to run a different code according to the runtime mode of the project. This function is useful to differentiate the initialization code of the project used by the application from the one used by the component. New in version 2025Syntax
<Result> = InComponentMode()
<Result>: Boolean - True if the code is run from a component,
- False if the code is run from a WINDEV application, WEBDEV website or PHP page.
Remarks Differentiating a code run in an component from a code run in a project (WINDEV or WEBDEV) In a project used both to create an executable or a site and to create a component, this function is used to run a different code according to the runtime mode of the project. This function allows you to run a distinct code: - in the initialization code of the project. Indeed, this code is common to the application (executable) and to the component (WDK file) created from the same project.
- in a class, a set of procedures, a window, ... shared between a project used to create a WINDEV application (executable) and a project used to create a component (WDK file).
Component test mode When testing a component, it is considered as a stand-alone application. InTestMode returns True. Function availability InComponentMode can be used in all IDEs to allow for cross-platform code. Functions or procedures that use InComponentMode can be shared between several products without generating any compilation error. Business / UI classification: Neutral code
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|