- Messages
- 240
- Country
-
Hi all! 
Just a quick question that I couldn't come up with a soluton yet:
I have a simple rotating knob...L:Var....it rotates from 0 - 6.
When it is at 6 and you click on it another time, I want it to turn FURTHER IN THE ORIGINAL DIRECTION back to 0. (to start over again)
At the moment it rotates ALL THE WAY BACK through 5, 4, 3, 2, 1 back to 0.
Which code do I have to use??
Here is my one:
Many thanks in advance,
Steven
Just a quick question that I couldn't come up with a soluton yet:
I have a simple rotating knob...L:Var....it rotates from 0 - 6.
When it is at 6 and you click on it another time, I want it to turn FURTHER IN THE ORIGINAL DIRECTION back to 0. (to start over again)
At the moment it rotates ALL THE WAY BACK through 5, 4, 3, 2, 1 back to 0.
Which code do I have to use??
Here is my one:
Code:
<Gauge Name="Air conditioning temp select" Version="1.0">
<Element>
<Position X="27" Y="27"/>
<Image Name="Startselect_Off.bmp" PointsTo="West" Bright="yes">
<Axis X="27" Y="29"/>
</Image>
<Rotate>
<Value Minimum="0" Maximum="6">(L:AirConSel,enum)</Value>
<Nonlinearity>
<Item Value="0" Degrees="180"/>
<Item Value="1" Degrees="225"/>
<Item Value="2" Degrees="304"/>
<Item Value="3" Degrees="339"/>
<Item Value="4" Degrees="30"/>
<Item Value="5" Degrees="60"/>
<Item Value="6" Degrees="135"/>
<Item Value="0" Degrees="540"/>
</Nonlinearity>
<Delay DegreesPerSecond="160"/>
</Rotate>
</Element>
<Mouse>
<Cursor Type="Hand"/>
<Click Kind="LeftSingle+RightSingle+WheelUp+WheelDown">
(M:Event) 'LeftSingle' scmp 0 == (M:Event) 'WheelUp' scmp 0 == or if{ (L:AirConSel,enum) ++ s0 6 > if{ 0 } els{ l0 } (>L:AirConSel, enum) }
(M:Event) 'RightSingle' scmp 0 == (M:Event) 'WheelDown' scmp 0 == or if{ (L:AirConSel,enum) -- s1 0 < if{ 6 } els{ l1 } (>L:AirConSel, enum) }
</Click>
</Mouse>
</Gauge>
Many thanks in advance,
Steven