Ti allego il codice e grazie di tutto
-------------------------------------
'OBJECT WEBCAM
S = S & "<p align=center>OPZIONI</font></p>"
S = S & "<TABLE id=TABLE1 style=WIDTH: 400px; HEIGHT: 400px height=250 cellSpacing=1 cellPadding=1 width=200 align=center border=0>"
S = S & "<TR>"
S = S & "<TD>"
S = S & "<OBJECT ID='CominsCamX' width=320 height=240 CLASSID='CLSID:A1D73A93-3CFA-4047-8256-9B704AEF0F74' codebase='CominsCamX.cab#Version=1,0,1,3'>"
S = S & "</OBJECT>"
S = S & "<form id=form1 name=form1>"
S = S & "<input type=text value=WebCam View1 name=txtCamName size=8>"
S = S & "<input type=text value=10.0.0.239 name=txtIP size=10>"
S = S & "<input type=text value=700 name=txtPort size=3>"
S = S & "<input type=text value='' id=txtID name=txtID size=4>"
S = S & "<input type=text value='' id=txtPass name=txtPass size=4>"
S = S & "<input type=button value=Connect onclick=Connect()>"
S = S & "</form>"
S = S & "</TD>"
S = S & "</TR>"
S = S & "</TABLE>"
S = S & "</BODY>"
Response.Write S
%>
<script language="JavaScript">

function Connect()
{
CominsCamX.SetCamData(form1.txtCamName.value, form1.txtIP.value, form1.txtPort.value,
form1.txtID.value, form1.txtPass.value);
CominsCamX.ConnectVideo();
}

function _valori(){
this.user=""
this.pwd=""
this.stato=""
}

var dati = new Array()
dati[0] = new _valori()
dati[0].user = "fra"
dati[0].pwd = "fra"
dati[0].stato = "libero"
dati[1] = new _valori()
dati[1].user = "rossano"
dati[1].pwd = "rossano"
dati[1].stato = "libero"
dati[2] = new _valori()
dati[2].user = "angela"
dati[2].pwd = "angela"
dati[2].stato = "libero"
dati[3] = new _valori()
dati[3].user = "max"
dati[3].pwd = "max"
dati[3].stato = "libero"

for (var i=0; i<dati.length; i++)
{
if (dati[i].stato=="libero")
{
dati[i].stato="occupato";
alert("utente "+dati[i].user+" password "+dati[i].pwd+": modificato stato da libero a occupato");
document.form1.txtID.value = dati[i].user;
document.form1.txtPass.value = dati[i].pwd;
break;
}
}

</script>
-----------------------------------------