Re: Calculating Totals

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: Pisoot Senethavilay (pisoot_at_senethavilay.com)
Date: 04/02/04


Date: Fri, 02 Apr 2004 11:00:12 -0800

Thank you for the reply, but when I put that in, the result I got was

0123

Rather than adding the 3 variables values. Here's what I used.

<%
 Dim nPayTotNum
 nPayTotNum = 3
 nPayAMT1 = 20
 nPayAMT2 = 20
 nPayAMT3 = 20
%>
<%
for i = 1 to nPayTotNum
    nSum = nSum + nPayAMT & i

next
%>
<%=nSum%>

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!