Question
Focus on first field on open
I have stumbled into a nice on OpenPage javascript that automatically set the focus on the first field to be filled. Nice.
if (typeof x == "undefined")
{
var x = 1
var premier = this.getField("T1");
premier.setFocus(); }
But why the if statement to check for var x? What does it do exactly? I can get the same results without it by using only teh last two lines.

