Link to home
Create AccountLog in
Avatar of Softacid
Softacid

asked on

ASP simple array SUM

Hello i have this code:
<%
Dim MyString, MyArray
MyString = "1,2"
MyArray = Split(MyString,",")
For i=0 to UBound(MyArray) 
 intTotal = intTotal + MyArray(i)
 
 Next 
 response.Write(intTotal)%>

Open in new window


instead of show me 3 it show me 12 .. where's the mistake?

thank you
ASKER CERTIFIED SOLUTION
Avatar of Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3]
Flag of Luxembourg image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of Softacid
Softacid

ASKER

thank you
glad I could help!

these points are the ones that made my 35 Millions complete :)

wish you a good year 2011!

angel eyes
Happy that we could help together :)
Happy Better  New year to u2