+ Reply to Thread
Results 1 to 3 of 3

Is there a way to go to "next i" in the middle of for loop?

  1. #1
    Forum Contributor
    Join Date
    06-14-2010
    Location
    Toronto,Canada
    MS-Off Ver
    Excel 2003
    Posts
    145

    Is there a way to go to "next i" in the middle of for loop?

    Hi,
    I am trying to make a sub right now that places checkmarks on the selected cells.
    I was wondering if another way to go to "next i" statement in an if statement that;s inside a for loop.
    For example, i want to make it so that if a user selects a range of cells, then the program will check for row number of each of those cells. If the cell rows are between 1 and 7, the checkmark won;t be placed there, but will continue to place checkmarks on rest of the rows (in the selection)
    I tried this but got an error
    Please Login or Register  to view this content.
    Thanks in advance
    Last edited by adds007; 07-22-2010 at 03:36 PM.

  2. #2
    Forum Guru romperstomper's Avatar
    Join Date
    11-04-2008
    Location
    A1
    MS-Off Ver
    Most
    Posts
    12,302

    Re: Is there a way to go to "next i" in the middle of for loop?

    Address the If part the other way round, and only perform the rest if the row is greater than or equal to 7:
    Please Login or Register  to view this content.
    Remember what the dormouse said
    Feed your head

  3. #3
    Forum Contributor
    Join Date
    06-14-2010
    Location
    Toronto,Canada
    MS-Off Ver
    Excel 2003
    Posts
    145

    Re: Is there a way to go to "next i" in the middle of for loop?

    Sorry for late reply, I never had this thread to instant notification
    But thanx for your replay, I used your solution
    I don;t know what I was thinking, that was an easy solution

    thanksss!! again

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1