prova questo codice così com'è
codice:
<%@ Language=VBScript %>
<%
partecipanti=1
maxArticoli=10
%>
<HTML>
<HEAD>
<script language="vbscript">
function Calcola(C1,C2,T)
T.value=FormatNumber(Replace(C1.value,".",",")*C2.value,2)
TOTALE()
end function
function TOTALE()
TOTALE=0
for i=1 to <%=maxArticoli%>
TOTALE=TOTALE+eval("T" & i & ".value")
next
TT.value = TOTALE
end function
</script>
</HEAD>
<BODY>
<table>
<%for i=1 to maxArticoli%>
<tr>
<td width="60%" align="left" class="recordV">
<input type="text" name="Descrizione<%=i%>" id="Descrizione<%=i%>" size="65" maxlength="60">
</td>
<td width="22%" align="center" class="recordV">
€. <input type="text" name="ImpPerPersona<%=i%>" style="text-align: right" size="10" value="0,00" onchange="Calcola ImpPerPersona<%=i%>,N<%=i%>,T<%=i%>">
</td>
<td width="8%" align="center" class="recordV">
<input type="text" name="N<%=i%>" size="2" value="<%=partecipanti%>" onchange="Calcola ImpPerPersona<%=i%>,N<%=i%>,T<%=i%>">
</td>
<td width="10%" align="center" class="recordV">
<input type="text" name="T<%=i%>" size="5" value="0,00"></td>
</td>
</tr>
<%next%>
<tr>
<td colspan="3" align="right">Totale</td>
<td align="center">
<input type="text" name="TT" size="5" value="0,00">
</td>
</table>
</BODY>
</HTML>