If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > JAVA > JavaScript Question

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-25-10, 23:04
myle myle is offline
(Making Your Life Easy)
 
Join Date: Feb 2004
Location: New Zealand
Posts: 1,143
JavaScript Question

I this Code

function addBarcodeText(brcc)
{
var ele = document.createElement("input");
var bri = document.createElement("BR");
var div = document.createElement("div")
var num = parseInt(document.getElementById("Bars").value);
num += 1 ;
document.getElementById("Bars").value = num;
var stnum = num+'';
var LL = 3 - (stnum.length);
var rep = repeat("... ",LL,LL)
div.innerHTML ="Scan " + num + rep
ele.setAttribute("type", "text");
ele.setAttribute("name", "Barcode");
ele.setAttribute("ID", "Barcode");
ele.setAttribute("size", "30");
ele.setAttribute("value", brcc);
ele.setAttribute("onfocus", "addBarcodeText('')");
var BarC = document.getElementById("BarC");
//BarC.appendChild(bri);
BarC.appendChild(div);
div.appendChild(ele);
if (num == 1)
{
ExpandSection('Mess1')
var elem = document.forms["FormName"].elements["Barcode"];
elem.focus();
}
}

and if I pass

<script> <!-- EDIT MODE ASP FULL JAVA addBarcodeText(Barcode); -->
addBarcodeText('12345');

addBarcodeText('12346');

addBarcodeText('123');

addBarcodeText('711719636182');

addBarcodeText('3307210222572');

addBarcodeText('');
</script>

Its work Great in firefox and on a max machine BUT not IN IE only will pass the 1st one

any Ideas

I use the Same form For Add/Edit New Item

when in new mode the onBlur create the Next Barcode Box !!GREAT!!
my code see it as a array and break it down OK

its IE that has me STUMP
__________________
hope this help

See clear as mud


StePhan McKillen
the aim is store once, not store multiple times
Remember... Optimize 'til you die!
Progaming environment:
Access based on my own environment: DAO3.6/A97/A2000/A2003
VB based on my own environment: vb6 sp5
ASP based on my own environment: 5.6
VB-NET based on my own environment started 2007
SQL-2005 based on my own environment started 2008
MYLE
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On