closeDisplay: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - " <h3 style="display:none">Notes</h3> <dl class="command_description"> <!-- Note Section BEGIN --> <!-- Note Section END --> </dl> " to "") |
Lou Montana (talk | contribs) m (Text replacement - " *\| *([Cc]omments|COMMENTS|Game|[Gg]ame [Nn]ame|Game [Vv]ersion|Game Version \(number surrounded by NO SPACES\)|Multiplayer Arguments( \("local" or "global"\))?|Effects|Multiplayer Effects( \("local" or "global"\))?|Multiplayer Exe...) |
||
Line 1: | Line 1: | ||
{{Command | {{Command | ||
| arma1 | | arma1 | ||
|1.00 | |1.00 | ||
|gr1= GUI Control | |gr1= GUI Control | ||
| 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 12: | Line 12: | ||
#define IDC_CANCEL 2 // emulate "Cancel" button | #define IDC_CANCEL 2 // emulate "Cancel" button | ||
</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.}} | {{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.}} | ||
| display [[closeDisplay]] exitCode | | display [[closeDisplay]] exitCode | ||
|p1= display: [[Display]] | |p1= display: [[Display]] | ||
|p2= exitCode: [[Number]] | |p2= exitCode: [[Number]] | ||
| [[Nothing]] | | [[Nothing]] | ||
|x1= <code>_display [[closeDisplay]] 1;</code> | |x1= <code>_display [[closeDisplay]] 1;</code> | ||
|x2= <code>#define IDC_OK 1 | |x2= <code>#define IDC_OK 1 | ||
_display [[closeDisplay]] IDC_OK;</code> | _display [[closeDisplay]] IDC_OK;</code> | ||
|[[createDisplay]], [[closeDialog]] | |[[createDisplay]], [[closeDialog]] | ||
}} | }} | ||
Revision as of 00:13, 18 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