Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: RE: Adding 2 arrays together


Message #1 by Colin.Montgomery@C... on Wed, 6 Mar 2002 18:17:21 -0000
in what way?  Are both arrays filled with Integers or what?  If integers,

and you want to add all the integers in array1 together, and then array2,

and then add the two results, it's simple:



(assume array1 and array2 have been DIM'ed and filled with integers)



Dim intCount, iItem

intCount = 0



For Each iItem in array1

	intCount=intCount + iItem

Next



For Each iItem in array2

	intCount=intCount + iItem

Next



Response.Write intCount



HTH,

Col



-----Original Message-----

From: imran.saleem@b... [mailto:imran.saleem@b...]

Sent: 06 March 2002 16:24

To: ASP Databases

Subject: [asp_databases] Adding 2 arrays together





Hi,

   can anyone tell me how i could add the contects of 2 arrays together.

Thanks for your help




$subst('Email.Unsub').





*******



This message and any attachment are confidential and may be privileged or otherwise protected from disclosure.  If you are not the
intended recipient, please telephone or email the sender and delete this message and any attachment from your system.  If you are
not the intended recipient you must not copy this message or attachment or disclose the contents to any other person.



For further information about Clifford Chance please see our website at http://www.cliffordchance.com or refer to any Clifford
Chance office.

Message #2 by imran.saleem@b... on Wed, 6 Mar 2002 16:23:52
Hi,

   can anyone tell me how i could add the contects of 2 arrays together.

Thanks for your help

  Return to Index