Thursday, January 17, 2013

[VisualForce] Block Auto Focus on DatePicker

This little post is born to remember how to avoid auto focus on Visualforce page of a DatePicker field, in case it is the first "focusable" field in the page:
 
     //avoid autofocus on date pickers
     function setFocusOnLoad() {}

This is something I have found online some weeks ago, but I can't remember the original post. So if you claim the paternity of this fix, I'll be glad to add a reference link.

No comments:

Post a Comment