Print Page | Close Window

Array calculation

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=17119
Printed Date: 29 March 2026 at 6:49pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Array calculation
Posted By: ainsworth14
Subject: Array calculation
Date Posted: 02 November 2005 at 3:17pm
Hi, hopefully someone can help or guide me.
 
I have a multi dimensional array. I want to calculate the sum of the 2nd dimension. If i try to do a basic calcualtion using '+' it literally adds the second value on to the end of the first like
 
2.50.05
 
instead of actually calculating the sum of the two. Hopefully you know what i mean?!
 
i want to add 2.50 and 0.50 together to make 3.
 
any help appreciated!
thanks
mark
 
 



Replies:
Posted By: michael
Date Posted: 02 November 2005 at 4:32pm
instead of just doing array(x) + array(y) do CDbl(array(x)) + CDbL(array(y))
This should do math as opposed to concatenation.


-------------
http://baumannphoto.com" rel="nofollow - Blog | http://mpgtracker.com" rel="nofollow - MPG Tracker


Posted By: ainsworth14
Date Posted: 03 November 2005 at 6:10pm
i thnk you have solved my problems!
 
everything seems to work!
THANK YOU Tongue
 
 



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net