Forums

ASP

This topic is locked

adding numbers for totals

Posted 26 Jun 2002 12:54:36
1
has voted
26 Jun 2002 12:54:36 Darren Bennett posted:
I have a table with a repeating region, bringing in a number of records which have a currency field.

Can I use any vbscript to get a sum total of this field and display it in a cell to show the total

Replies

Replied 26 Jun 2002 18:33:48
26 Jun 2002 18:33:48 Owen Eastwick replied:
Before the repeat region code at the bottom of the repeat region add the following:

<%
varTotal = varTotal + RecordsetName.Fields.Item("CurrencyFieldName".Value
%>

Then you can display the total on the page:

<%= varTotal %>

Regards

Owen.

Multiple Parameter UD4 / Access 2000 Database Search Tutorial:
www.tdsf.co.uk/tdsfdemo

Reply to this topic