closeDisplay: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\[\[Category:[ _]?Scripting[ _]Commands[ _]Take[ _]On[ _]Helicopters(\|.*)?]]" to "{{GameCategory|tkoh|Scripting Commands}}") |
Lou Montana (talk | contribs) m (Text replacement - "_{10,} " to "") |
||
Line 1: | Line 1: | ||
{{Command|Comments= | {{Command|Comments= | ||
| arma1 |Game name= | | arma1 |Game name= | ||
Line 7: | Line 6: | ||
|gr1= GUI Control |GROUP1= | |gr1= GUI Control |GROUP1= | ||
| Closes given display with exit code. It does not instantly close the display but does it on next simulation cycle. Most common exit codes are: | | Closes given display with exit code. It does not instantly close the display but does it on next simulation cycle. Most common exit codes are: | ||
Line 15: | Line 13: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
{{Important | Sometimes when one display is opened on top of another display, previous display may not close properly, i.e. some display EHs such as "onUnload" may never fire. Use this command to manually handle such displays.}} |DESCRIPTION= | {{Important | Sometimes when one display is opened on top of another display, previous display may not close properly, i.e. some display EHs such as "onUnload" may never fire. Use this command to manually handle such displays.}} |DESCRIPTION= | ||
| display [[closeDisplay]] exitCode |SYNTAX= | | display [[closeDisplay]] exitCode |SYNTAX= | ||
Line 24: | Line 21: | ||
| [[Nothing]] |RETURNVALUE= | | [[Nothing]] |RETURNVALUE= | ||
|x1= <code>_display [[closeDisplay]] 1;</code> |EXAMPLE1= | |x1= <code>_display [[closeDisplay]] 1;</code> |EXAMPLE1= | ||
Line 30: | Line 26: | ||
|x2= <code>#define IDC_OK 1 | |x2= <code>#define IDC_OK 1 | ||
_display [[closeDisplay]] IDC_OK;</code> |EXAMPLE2= | _display [[closeDisplay]] IDC_OK;</code> |EXAMPLE2= | ||
|[[createDisplay]], [[closeDialog]]|SEEALSO= | |[[createDisplay]], [[closeDialog]]|SEEALSO= |
Revision as of 00:23, 17 January 2021
Description
- Description:
- Closes given display with exit code. It does not instantly close the display but does it on next simulation cycle. Most common exit codes are:
#define IDC_OK 1 // emulate "OK" button #define IDC_CANCEL 2 // emulate "Cancel" button
- Groups:
- GUI Control
Syntax
- Syntax:
- display closeDisplay exitCode
- Parameters:
- display: Display
- exitCode: Number
- Return Value:
- Nothing
Examples
- Example 1:
_display closeDisplay 1;
- Example 2:
#define IDC_OK 1 _display closeDisplay IDC_OK;
Additional Information
- See also:
- createDisplaycloseDialog
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note