I understand that with javascript you can select the contents of a textbox with the following code (in jQuery):
$(\"#txt1\").select();
Is t
Rather than selecting and then deselecting, why not just temporarily store a boolean on the dom element?
$("input[type=text]").focus(function() { if($(this).skipFocus) return; $(this).select(); }); //code.... $("#txt1").skipFocus = true; $("#txt1").focus();