Hello, I have a barcode scanner and when a field is scanned it should autotab to the next field for population. I have tried this before but cannot seem to get it to work the way I would like. It should auto tab if the field in not null, i have tried this code but cannot seem to get it working unless it is using a fixed size. f3 works f2 doesn't Thanks.
function check2()
{
var work = document.getElementById("workArea");
var letters2 = document.inputData.workArea.value.length +1;
if ( letters2 == null )&&( letters2 == "")
{document.inputData.partNumber.focus()}
else
{document.inputData.workArea.focus()}
}
function check3()
{
var letters3 = document.inputData.partNumber.value.length +1;
if (letters3 <10)
{document.inputData.partNumber.focus()}
else
{document.inputData.quantity.focus()}
}
<%-- work area --%>
<p style="text-align:left;margin-top:-10px;">Part#: <input type="text" id="partNumber" name="partNumber" property="partNumber" onKeyUp="check2()" value='<%= form.getPartNumber() %>'/></p>