Difference between revisions of "Extensions.HMI.ScreenIsOpen"

From emotive
Jump to navigation Jump to search
 
(6 intermediate revisions by one other user not shown)
Line 1: Line 1:
 
{{DISPLAYTITLE:  '''ScreenIsOpen'''}}[[Category:HMI]]
 
{{DISPLAYTITLE:  '''ScreenIsOpen'''}}[[Category:HMI]]
 
== Classification ==
 
== Classification ==
{{ClassificationActivity | ScreenIsOpen | Verifies whether a screen is open and active | [[Term]] | [[Extensions.HMI|OTX HMI extension]] | [[HMI related terms]] | - | - }}
+
{{ClassificationActivity | ScreenIsOpen | Verifies whether a screen is open and active | [[Term]] | [[Extensions.HMI|OTX HMI extension]] | [[Extensions.HMI#Terms|HMI related terms]] | - | - }}
  
 
== OTL Syntax ==
 
== OTL Syntax ==
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
BooleanTerm = Hmi.ScreenIsOpen(ScreenVariable);
+
BooleanTerm HMI.ScreenIsOpen(ScreenVariable screen);
 
</syntaxhighlight>
 
</syntaxhighlight>
  
 
== Description ==
 
== Description ==
This term is used to ensure that a ''screen'' is open and active.
+
The '''ScreenIsOpen''' term is used to verify that a ''Screen'' is open and active. A ''Screen'' is open and active if it has been opened by using an [[Extensions.HMI.OpenScreen|'''OpenScreen''']] action, it has not been dismissed by the user and it has not been closed by using a [[Extensions.HMI.CloseScreen|'''CloseScreen''']] action.
 +
 
 +
{{Important|Due to the fact that there may be multiple parallel lanes, and that a screen engine normally works in a different thread, if the ''ScreenIsOpen'' term returns true there is actually no guarantee that the screen is still open on the next step.}}
  
 
{{TermReturnValue| [[Core.DataTypes.SimpleDataType.Boolean|Boolean]] | This value is TRUE if the screen is open and active.}}
 
{{TermReturnValue| [[Core.DataTypes.SimpleDataType.Boolean|Boolean]] | This value is TRUE if the screen is open and active.}}
Line 16: Line 18:
 
{| {{TableHeader}}
 
{| {{TableHeader}}
 
{{TableRowPropertiesHeader}}
 
{{TableRowPropertiesHeader}}
{{TableRowPropertie1| Screen | [[Extensions.HMI.Screen|Screen]] | [[Variable]] | - | [1] |The variable being evaluated, which is a handle on the Screen}}
+
{{TableRowPropertie2| Screen | [[Extensions.HMI.Screen|Screen]] | [[Variable]] | - | [1] |This element represents the variable which is a handle to the screen that will be checked.}}
 
|}
 
|}
  
 
== OTL Examples ==
 
== OTL Examples ==
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
 
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;">
package Hmi.ScreenSignature ScreenSignature1(ref Integer ScreenInOutParameter1);
+
/// Signatures
 +
 
 +
package HMI.ScreenSignature ScreenSignature1(ref Integer ScreenInOutParameter1);
 +
 
 +
/// Global Declarations
  
 
public procedure main()
 
public procedure main()
 
{
 
{
  Hmi.Screen ScreenHandle1;
+
/// Local Declarations
  Boolean Boolean1 = false;
+
 
 +
HMI.Screen ScreenHandle1;
 +
Integer Integer1;
 +
Boolean Boolean1 = false;
 +
 
 +
/// Flow
  
  Hmi.OpenScreen(ScreenSignature1, false, {ref ScreenInOutParameter1 = ScreenInOut1}, ScreenHandle1);
+
HMI.OpenScreen(ScreenHandle1, ScreenSignature1, {ScreenInOutParameter1 = Integer1}, false);
  Boolean1 = Hmi.ScreenIsOpen(ScreenHandle1);
+
Boolean1 = HMI.ScreenIsOpen(ScreenHandle1);
 
}
 
}
 
</syntaxhighlight>
 
</syntaxhighlight>

Latest revision as of 02:36, 13 September 2019

Classification

Name ScreenIsOpen
Short Description Verifies whether a screen is open and active
Class Term
Extension OTX HMI extension
Group HMI related terms
Exceptions -
Checker Rules -
Standard Compliant Yes

OTL Syntax

BooleanTerm HMI.ScreenIsOpen(ScreenVariable screen);

Description

The ScreenIsOpen term is used to verify that a Screen is open and active. A Screen is open and active if it has been opened by using an OpenScreen action, it has not been dismissed by the user and it has not been closed by using a CloseScreen action.

Exclamation.png Important: Due to the fact that there may be multiple parallel lanes, and that a screen engine normally works in a different thread, if the ScreenIsOpen term returns true there is actually no guarantee that the screen is still open on the next step.

Return Value

The Term returns the value, see table below.

Icons Note.png In OTX, Terms are categorized according to its return data type!
Data Type Description
Boolean This value is TRUE if the screen is open and active.

Properties

Name Data Type Class Default Cardinality Description
Screen Screen Variable - [1] This element represents the variable which is a handle to the screen that will be checked.

OTL Examples

/// Signatures

package HMI.ScreenSignature ScreenSignature1(ref Integer ScreenInOutParameter1);

/// Global Declarations

public procedure main()
{
	/// Local Declarations

	HMI.Screen ScreenHandle1;
	Integer Integer1;
	Boolean Boolean1 = false;

	/// Flow

	HMI.OpenScreen(ScreenHandle1, ScreenSignature1, {ScreenInOutParameter1 = Integer1}, false);
	Boolean1 = HMI.ScreenIsOpen(ScreenHandle1);
}

See also

ScreenClosedEventSource
IsScreenClosedEvent