probabilmente sbaglio qualcosa,
l'errore penso sia nel Record SEt
![]()
<%@LANGUAGE = JScript%>
<%
/*
Autore: Luca Ruggiero - http://www.lukeonweb.net
Fonte: freeAsp.it - http://freeasp.html.it
*/
if (Session("username") == null)
{
Response.Write("ACCESSO NEGATO!");
Cn.Close();
Response.End;
}
var azione = new String(Request.QueryString("azione"))
%>
<html>
<head>
<title>risultati eccellenza inserimento</title>
<style type="text/css">
td, p, input, textarea { font-size: 12px; font-family: Verdana; }
a { color: #000080; text-decoration: None; }
a:hover { color: #800000; text-decoration: Underline; }
</style>
<link rel="stylesheet" type="text/css" href="../pagine/stadioradionew/style.css">
</head>
<body>
<table align="center" width="623" cellpadding="1" cellspacing="0" style="border: 1px Solid #000000">
<form method="post" action="insrisecc.asp?azione=Inserisci">
<tr>
<td bgcolor="#008080" width="617" align="center"><font color="#FFFFFF">risultati eccellenza
</font><font color="#FF0000">inserimento</font></td>
</tr>
<tr>
<td width="617">
<table border="0" width="100%" height="196">
<tr>
<td width="26%" height="14" align="center"><font color="#FF0000">casa</font></td>
<td width="24%" height="14" align="center"><font color="#FF0000">fuori</font></td>
<td width="25%" height="14" align="center"><font color="#FF0000">risultato</font></td>
<td width="25%" height="14" align="center"><font color="#FF0000">parziale - finale</font></td>
</tr>
<tr>
<td width="26%" height="30">
<input type="text" name="casa1" style="width: 154; height: 23" size="20">
</td>
<td width="24%" height="30">
<input type="text" name="fuori1" style="width: 100%" size="20"></td>
<td width="25%" height="30">
<input type="text" name="risultato1" style="width: 100%" size="20"></td>
<td width="25%" height="30"><input type="text" name="parz-fin1" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa2" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori2" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato2" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin2" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa3" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori3" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato3" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin3" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa4" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori4" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato4" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin4" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa5" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori5" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato5" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin5" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa6" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori6" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato6" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin6" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa7" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori7" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato7" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin7" style="width: 100%" size="20"></td>
</tr>
<tr>
<td width="26%" height="14"><input type="text" name="casa8" style="width: 154; height: 23" size="20"></td>
<td width="24%" height="14">
<input type="text" name="fuori8" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="risultato8" style="width: 100%" size="20"></td>
<td width="25%" height="14">
<input type="text" name="parz-fin8" style="width: 100%" size="20"></td>
</tr>
</table>
<% var casa, fuori, risultato, parzfin, count;
count=1;
%>
<%if (azione == "undefined" ) {%>
<div align="right"><input type="submit" value="Inserisci"></div>
<%
}
else if (azione == "Inserisci" )
{
if (count <=8)
{
casa= new String(Request.Form("casa(count)"));
fuori= new String(Request.Form("fuori(count)"));
risultato= new String(Request.Form("risultato(count)"));
parzfin= new String(Request.Form("parz-fin(count)"));
var Rs = new ActiveXObject("ADODB.Recordset");
Rs.Open("risultati",Cn,4,4);
Rs.AddNew();
Rs("casa") = casa;
Rs("fuori") = fuori;
Rs("risultato")= risultato;
rs("finpar")= parzfin;
Rs.Update();
Rs.Close();
count=count+1;
}
else
{
Response.Write("<p align='center'>Dati inseriti con successo!
Nuova</p>");
}
}
else
{
Cn.Close();
Response.Redirect("logout.asp");
}
%>
</td>
</tr>
</form>
</table>
<p align="center">Logout</p>
</body>
</html>
<%Cn.Close()%>

Rispondi quotando
