Re: Filling an array with a Loop

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Dim ends(5) As Integer
For d = 5 to 0 step -1
ends(d) = Range("A50000").End(xlUp).Row
Next d

Better. It works, but, my array size will not always be 5 (6 including
0). It must be constant? My loop steps backwards, and fills my array
backwards. How can I reverse it?

.



Relevant Pages

  • Re: The name of script itself
    ... You need this instead if you want to do it in a loop: ... even though he's accessing the array in random order, ... Prev by Date: ...
    (comp.lang.awk)
  • Re: minimum value in an array
    ... >> an array apart for using for loops? ... Karl just chose to loop forwards and use a <= comparison whereas I ... looping backwards seemed more "natural". ... accomplish a task and the different ways people will provide to accomplish ...
    (microsoft.public.vb.general.discussion)
  • Re: elegant solution for counting runs
    ... has to test (within a loop through the sequence) for the first ... Shift the array by 1 and check if the entries in the new array and ... entries that did match. ... prev) then ...
    (comp.lang.fortran)
  • Re: For Loop Help
    ... just use an array: ... > To a for loop that changes the variable name so I don't have to list them, ... 'Faith without judgement merely degrades the spirit divine.' ... Prev by Date: ...
    (comp.lang.javascript)
  • Muti Dimmed Array Problem
    ... I am trying to create an array that will eventually loop to update ... corresponding record in a database. ... Prev by Date: ...
    (microsoft.public.scripting.vbscript)