CursorItemId (Screen function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (1 revision)
mNo edit summary
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Template:Screen:CursorItemId subtitle}}
{{Template:Screen:CursorItemId subtitle}}
 
<var>CursorItemId</var> is a [[Notation_conventions_for_methods#Callable_methods|callable]] function that returns the numeric item ID of the <var>[[Screen classes#Screens and ScreenFields|ScreenField]]</var> where the cursor is currently located. A <var>ScreenField</var> is assigned an item ID either when it is instantiated by the <var>[[AddField_(Screen_function)|AddField]]</var> method, or if it is (re-)specified with the <var>[[Itemid_(ScreenField_property)|Itemid]]</var> method.
This callable function returns the numeric item ID of the ScreenField where the cursor is located. A ScreenField is assigned an item ID either when it is instantiated by the AddField method (&amp;amp;#x201C;AddField&amp;amp;#x201D; on page 894), or if it is specified with the [[Screenfield class#Itemid property|Screenfield Itemid method]].


==Syntax==
==Syntax==
{{Template:Screen:CursorItemId syntax}}
{{Template:Screen:CursorItemId syntax}}
===Syntax terms===
===Syntax terms===
<table class="syntaxTable">
<table class="syntaxTable">
<tr><th>%num</th>
<tr><th>%num</th>
<td>A numeric variable to contain the returned item ID. If no item ID was assigned to the screenField, zero is returned. </td></tr>
<td>A numeric variable to contain the returned item ID. If no item ID was assigned to the <var>screenField</var>, zero is returned. </td></tr>
<tr><th>%screen</th>
 
<td>A reference to an instance of a Screen object.</td></tr>
<tr><th>screen</th>
<td>A reference to an instance of a <var>Screen</var> object.</td></tr>
</table>
</table>
==See also==
==See also==
{{Template:Screen:CursorItemId footer}}
{{Template:Screen:CursorItemId footer}}

Latest revision as of 22:38, 16 November 2012

Return the item ID of field at the cursor position (Screen class)

CursorItemId is a callable function that returns the numeric item ID of the ScreenField where the cursor is currently located. A ScreenField is assigned an item ID either when it is instantiated by the AddField method, or if it is (re-)specified with the Itemid method.

Syntax

[%number =] screen:CursorItemId

Syntax terms

%num A numeric variable to contain the returned item ID. If no item ID was assigned to the screenField, zero is returned.
screen A reference to an instance of a Screen object.

See also