Hi CBD,
I am a beginner myself and I know how it feels. Start by practicing examples in Prontoscript developers’ guide.
Get "JavaScript: The Definitive Guide"-David Flanagan, it will help you.
Have a look at the code below:
onRotary = function(clicks)
{
if (clicks > 0)
{System.print ("ROTARY Right");
GUI.widget("PS_PAGE_UP").executeActions();
//CF.widget("RIGHT", "ACTIONS", "RESOURCES").executeActions();
}
if (clicks < 0)
{System.print ("ROTARY Leftt");
GUI.widget("PS_PAGE_DOWN").executeActions();
//CF.widget("LEFT", "ACTIONS", "RESOURCES").executeActions();
}
};
-------
This is to execute PageUp and PageDown when you rotate the wheel.
If you uncomment the other lines, it will execute actions (whatever you choose: rs232, ir, ) of buttons "LEFT" & "RIGHT", located in the page named "ACTIONS" in activity/device "RESOURCES", which of course you have to create.
I hope it helps, however it is more fulfilling if you discover/write it yourself :)
Sorin
Last edited by sgtoma
on January 19, 2008 04:05.