loop break

  1. tourless

    Loop not breaking as expected

    Hi Folks, I have the following code that I'm expecting to break out of the loop once it no longer sees a match on the customer name. But what I'm noticing is the loop continues until it exhausts all rows in the range. I've tried a few variations with no luck so far... How can I get that to...
  2. J

    Loop Counting - Stop and Start based on a blank row

    I would like to loop count different sets of data. They are separated by a blank. Here is the VBA i have for counting but I want to make it loop for each data set. Sub RowCount() Dim countnonblank As Integer, myRange As Range Set myRange = Columns("A:A") countnonblank =...
  3. M

    Default Skipping an i, or multiple i's in a Loop - please help

    I am writing some code to generate multiple pivot tables in excel. My spreadsheet is set up with survey responses to a variety of questions with the question number across the top, and the survey responses below in the column. My problem relates to questions 8, 10, and 13. As you can see in my...
  4. A

    For...Next Loop Sticking

    I am using the following code to delete the header from each worksheet in a large Excel workbook. The code is running fine until it gets to one specific worksheet, then I receive the following error message: "Run-time error '1004': Select method of worksheet class failed". I have inserted this...
  5. S

    Please could someone help me stop my loop

    Hi I have been trying to write a loop macro that will delete various rows in my spreadsheet. It is deleting the right rows but i can't get it to stop. I have tried including a counter, sticking a safeword at the bottom of column A and stopping at the first empty cell in column A, but it keeps...
  6. D

    VBA loop not functioning - Please help!

    Hi, I have created a data entry macro that prompts the user for information and then enters it in the correct cell of the excel sheet. The user will be entering multiple lines of information so I need the macro called "newentry()" to repeat itself indefinitely, at least until the user clicks...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top