Jump to content
Sign in to follow this  
RickB75

how can I get the remaining part of an array thats different sizes?

Recommended Posts

RickB75

Guys,

     I have a quick question. I have a script thats building different sized arrays for me and I'm writing the data to excel. Heres an example.

[0]7

[1]2013

[2]Toyota

[3]Camry

[4]LE

[5]Sedan

[6]4 Door

The data in position 1,2 and 3 will always be written to the same columns in excel. How can I grab the data in the remaining positions and write it to a particular column.

 

Share this post


Link to post
Share on other sites
RickB75

lets say I want to grab position 5 and 6, would it be something like this?

For $i = 5 to Ubound(myarray)

 _ExcelWriteCell($oExcel,$marray[$i],$icounter,5)

Next

Ya know, just looking at this, I can pretty much tell it won't work because I'm still telling it a certain position to write. I guess I need to  remove the data from the first part of the array once I've used it and then write the remaining... I think

Edited by RickB75

Share this post


Link to post
Share on other sites
RickB75

Darn guys, I was just searching on google for an answer to my post here and my post is already indexed in google. Less than an hour later. Pretty impressive!!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×