lnbValue: Difference between revisions
Jump to navigation
Jump to search
m (Text replace - "{{uc:{{PAGENAME}}}}" to "{{uc:{{PAGENAME}}}} {{uc:{{PAGENAME}}}}") |
Fred Gandt (talk | contribs) m (General tidy + "see also" + format note) |
||
Line 21: | Line 21: | ||
|x1= <code> | |x1= <code>{{Example needed}}</code>|= Example 1 | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| | | [[lnbAddArray]], [[lnbAddColumn]], [[lnbAddRow]], [[lnbClear]], [[lnbColor]], [[lnbCurSelRow]], [[lnbData]], [[lnbDeleteColumn]], [[lnbDeleteRow]], [[lnbGetColumnsPosition]], [[lnbPicture]], [[lnbSetColor]], [[lnbsetColumnsPos]], [[lnbSetCurSelRow]], [[lnbSetData]], [[lnbSetPicture]], [[lnbSetText]], [[lnbSetValue]], [[lnbSize]], [[lnbText]] |= SEEALSO | ||
| |= MPBEHAVIOUR | | |= MPBEHAVIOUR | ||
Line 37: | Line 36: | ||
However, you can use the lbValue. | However, you can use the lbValue. | ||
Example (in the case of the 3 columns in the row): | Example (in the case of the 3 columns in the row): | ||
<pre>_rowSize = count getArray( | |||
missionConfigFile >> "RscMyDlg" >> "controls" >> "MyList" >> "columns" | |||
); | |||
_row = 12; | |||
_column = 2; | |||
_verificationValue = 9781; | |||
_ctrlMyList lnbSetValue [[_row, _column], _verificationValue]; | |||
_value = _ctrlMyList lbValue (_row * _rowSize + _column); | |||
hint str (_verificationValue == _value); // hint true</pre> | |||
While this bug is not fixed, we can use the macro: | While this bug is not fixed, we can use the macro: | ||
<pre>#define __lnbRowSize(lnb) ((lnbSize lnb) select 1) | |||
#define __lnbValue(lnb, row, col) ((lnb) lbValue ((row) * __lnbRowSize(lnb) + (col))) | |||
__lnbValue(_ctrlMyList, _row, _column);</pre> | |||
[[User:DenV|DenV]] | [[User:DenV|DenV]] |
Revision as of 06:03, 11 April 2014
Description
- Description:
- Returns the additional integer value in the item with the given position of the 2D listbox.
- Groups:
- Uncategorised
Syntax
- Syntax:
- lnbValue [idc,[row,column]
- Parameters:
- [idc,[row,column]: Array -
- Return Value:
- Number
Examples
- Example 1:
Template:Example needed
Additional Information
- See also:
- lnbAddArraylnbAddColumnlnbAddRowlnbClearlnbColorlnbCurSelRowlnbDatalnbDeleteColumnlnbDeleteRowlnbGetColumnsPositionlnbPicturelnbSetColorlnbsetColumnsPoslnbSetCurSelRowlnbSetDatalnbSetPicturelnbSetTextlnbSetValuelnbSizelnbText
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
Notes
-
It seems this command is don't have arma-style syntax (not work with control type).
However, you can use the lbValue.
Example (in the case of the 3 columns in the row):
_rowSize = count getArray( missionConfigFile >> "RscMyDlg" >> "controls" >> "MyList" >> "columns" ); _row = 12; _column = 2; _verificationValue = 9781; _ctrlMyList lnbSetValue [[_row, _column], _verificationValue]; _value = _ctrlMyList lbValue (_row * _rowSize + _column); hint str (_verificationValue == _value); // hint true
While this bug is not fixed, we can use the macro:
#define __lnbRowSize(lnb) ((lnbSize lnb) select 1) #define __lnbValue(lnb, row, col) ((lnb) lbValue ((row) * __lnbRowSize(lnb) + (col))) __lnbValue(_ctrlMyList, _row, _column);