Results 1 to 7 of 7

Thread: [RESOLVED] Skip cells containing text [Excel]

Hybrid View

  1. #1
    Addicted Member
    Join Date
    Jul 2008
    Location
    Colorado
    Posts
    193

    Re: Skip cells containing text [Excel]

    You could always use the below code to just run it if it is a number.

    Code:
    If Application.IsNumber(aCell.Value) = True Then
    Edit: I think you would put this after checking if it's a formula...
    Last edited by Fizziii; Jun 11th, 2009 at 09:10 AM.

  2. #2

    Thread Starter
    Member
    Join Date
    Oct 2008
    Location
    South Africa
    Posts
    32

    Re: Skip cells containing text [Excel]

    I knew it had to be simple! Thanks a lot.

    If I am allowed a follow up question:
    Can one split the for loop to skip a certain value, for example:

    For x = 1 to 5 and 7 to 10

    At the moment I am repeating the code to achieve the same:
    For x = 1 to 5
    ....
    ....
    For x = 7 to 10

    But would be more elegant if I could run all in one loop?

    Regards

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