Results 1 to 3 of 3

Thread: Excel VBA

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Mar 2000
    Location
    bebenia, PA, USA
    Posts
    241
    Need to start at "A" cell 5 rows down and loop 30 times what code would help me to do this and I need the rows to be shaded.

  2. #2
    Frenzied Member
    Join Date
    Jan 2000
    Location
    Bellevue, WA, USA
    Posts
    1,357

    What do you mean?

    Starting in cell A5 is easy...
    Code:
    Range("A5").Select
    But what do you want to do in your loop? Can you be more specific?
    ~seaweed

  3. #3
    Frenzied Member
    Join Date
    Jan 2000
    Location
    Bellevue, WA, USA
    Posts
    1,357
    If you mean you need to select column A, rows 5 through 35, then you can do this...
    Code:
    Range("A5:A35").Select
    Or if you just need to use a loop to select them, then try this:
    Code:
    Dim intRow As Integer
    
    For intRow = 5 To 35
        Range("A5:A" & intRow).Select
    Next ' intRow
    P.S. If you get stuck with VBA, the easiest way to figure out what to do is record a macro of what you want to do, then look at the code the macro generated. Then edit this to what you want.
    ~seaweed

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width