2021-11-14, 16:46
Is there a way to use a property in a list item to set the focus based on that value? I am setting two property values for each item "upId" and "downId" that I want to use to setFocus <onUp> and <onDown>.
I stripped down what I have to illustrate what I'm trying to do, but it doesn't work.
Is this not the right syntax for ListItem.Property?
Or can you not use a variable for SetFocus()?
I stripped down what I have to illustrate what I'm trying to do, but it doesn't work.
Is this not the right syntax for ListItem.Property?
Or can you not use a variable for SetFocus()?
xml:
<control type="fixedlist" id="90001">
<onleft>90001</onleft>
<onright>90001</onright>
<onup>SetFocus(9000,ListItem.Property(upId),absolute)</onup>
<ondown>SetFocus(9000,ListItem.Property(downId),absolute)</ondown>
<pagecontrol/>
<focusposition>1</focusposition>
<movement>1</movement>
<orientation>Horizontal</orientation>
<itemlayout height="65" width="150">
<control type="label">
<label>$INFO[ListItem.Label]</label>
</control>
</itemlayout>
<focusedlayout height="65" width="150">
<control type="label">
<label>$INFO[ListItem.Label]</label>
</control>
</focusedlayout>
<content>
<item id="1">
<label>Item 1</label>
<property name="upId">0</property>
<property name="downId">4</property>
</item>
<item id="2">
<label>Item 2</label>
<property name="upId">1</property>
<property name="downId">5</property>
</item>
</content>
</control>