...

View Full Version : Can't enter data into all new boxes



MRMAN
08-14-2007, 02:17 PM
Hello.

I have a script that will add up to 10 rows into a table. each row of the table contain. 2 text boxes and 4 drop down boxes.

But sometimes with i try to enter data into the last few text boxes i can't click into the box and enter data. i can only tab into the box and enter the data.

I was just wondering if there might be two many dynamic input boxes on the page or if




function AddRows(type)
{
if(RowCounter < 10)
{
RowCounter++;
var table = document.getElementById('tblResult');
var myRow=table.insertRow(RowCounter);
myRow.height="21px";
myRow.style.verticalAlign = "Top";
var cell1 = myRow.insertCell(0);
cell1.id = "oddsboxes"+RowCounter;
cell1.name = "oddsboxes"+RowCounter;
cell1.width = "150px";
cell1.height = "21px";
cell1.align = "center";
cell1.style.verticalAlign = "Top";
cell1.style.whiteSpace = "nowrap"
if(document.getElementById("hiddenoddsformat").value == "decimal")
{
cell1.innerHTML = GetInputBoxDecimal(RowCounter);
}
else
{
cell1.innerHTML = GetInputBoxFraction(RowCounter);
}

var cell2 = myRow.insertCell(1);
cell2.align = "center";
var box1 = document.createElement("select");
box1.name = "result"+RowCounter;
box1.id = "result"+RowCounter;
box1.options[0] = new Option("Won", "won");
cell2.appendChild(box1);

var cell4 = myRow.insertCell(2);
cell4.align = "center";
var box7 = document.createElement("select");
box7.name = "Terms"+RowCounter;
box7.id = "Terms"+RowCounter;
box7.options[0] = new Option("1/2", "2");

box7.selectedIndex = 2;
if(document.getElementById("PlaceTermsEW").checked == false)
{
box7.disabled = true;
}
cell4.appendChild(box7);

var cell5 = myRow.insertCell(3);
cell5.align = "center";
var box8 = document.createElement("select");
box8.name = "Rule4"+RowCounter;
box8.id = "Rule4"+RowCounter;
box8.options[0] = new Option("0", "00");
cell5.appendChild(box8);

var cell6 = myRow.insertCell(4);
cell6.align = "center";
var box9 = document.createElement("select");
box9.name = "Deadheat"+RowCounter;
box9.id = "Deadheat"+RowCounter;
box9.options[0] = new Option("N/A", "N/A");
cell6.appendChild(box9);

if(type == "button")
{
RemoveRow("blank");
}
}
}



the above code is just part of the insert function (i have taken all be one option of the select box.

Can anyone else. Cheers

Fumigator
08-14-2007, 09:17 PM
was just wondering if there might be two many dynamic input boxes on the page

I doubt it. But I guess it's possible. Try another browser maybe? Also if you could post a link to an example of this happening that would help us see what it's doing.

MRMAN
08-15-2007, 10:28 AM
I doubt it. But I guess it's possible. Try another browser maybe? Also if you could post a link to an example of this happening that would help us see what it's doing.

sorry ill get something together



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum