You shouldn't have to declare x with var.. I've used the js syntax numerous times.
for (i = 0; i < 10; i++) {
ogscript.debug('This is number ' + i);
};
Keep in mind that you can only use the "normal" booleans ( ) when editing in the ogscript editor of a task. If you edit directly in sourcecode you have to use < or >
#DashBoard