do until loop

  1. A

    Fill down formulas and Do Until "No more data"

    Hi I am new to Mr Excel, returning to VBA after many years' break (I've been using power query for most of my solutions) and am hoping that some of you clever people will be able to solve my conundrum. I have a spreadsheet that picks up data from another sheet from the same workbook, does a...
  2. S

    Loop until a cell is a certain number

    Hi, I have some code below where H8 is an invoice number which I will start at the number 4000. Cell Z1 is a customer name. I then want to run this code until all invoices are ran up to number 4300. So in essences running this piece of code 300 times with Invoice 4000 being the first one...
  3. C

    Do Until VBA Loop

    Hello, I'm trying to create a Do Until code in VBA that will populate a certain value in column A until a criteria is met in column B, after which it will populate a second value. I think this should be a relatively quick Do Until code, but unsure how to create it. Below is a quick example...
  4. A

    Extend columns in a do until loop

    I have written this code which draws data from a sheet to another with a do until loop but it does it only for 1 column (column U, the 21st column). I want to be able to perform this for 5 columns (columns U, V,W,X,Y). How should I change my code? Sub DrawData() Dim x As Integer x = 1 Do...
  5. Z

    Nested Web Scraping Breaks My Do Loop

    I am having trouble with a nested web scraping section breaking my Do Until Loop. I have a list that I am creating a unique file with two tabs. One contains some basic header information which I want to use to get the most relevant website and add the link. Then save, close and move on to the...
  6. A

    Do Until Loop Deletes and Creates New Sheet Instead of Skipping

    Hi all, I am revamping some code that aggregates data from several tabs of a workbook and copies them to another file, which is used as a link file in an Access Database. When the code goes into a Do Until loop, it processes the data fine, unless there is a blank tab and then a final tab with...
  7. M

    Do Until Question

    I have a Do until statement wrapped in an If statement and this is the Do until code I am using: DEPI = Sheets("MTN").Range("A1").End(xlDown).row Set findrange = Sheets("MTN").Range("A1:A" & DEPI) Set foundcell = findrange.Find(What:=Sheets("MTN").Range("C1").Value, LookIn:=xlValues...
  8. K

    Do Until Find a new value

    Hello, I have a table where in column A there are a set of data of all kinds. In some cells of this column there is the information that interest me, that comes in the form "account - xxxx"/ then a few rows below I'll find "account - yyyy", then "account - zzzz" and so on. xxxx, yyyy, zzzz...
  9. A

    Excel vba loop through list until

    Hello, I am trying to work on a way to automatically fill in a schedule for where someone should be. What I have so far is in my 1st sheet I have a table of cells I want to fill, across the columns i have dates, and down the rows I have the locations. In my 2nd sheet I have the dates of when...
  10. 3

    Please help! Looping for a product until a row is empty

    Hey Folks, Long time reader, first time poster. I'm trying to have my code enter a formula in T8 (and T9, T10, etc.) until there is no longer a value in cell in row 8. It is based off another format so I need it to start on cell T8 so it doesn't pick up the headers (hence me trying to...
  11. A

    Autocompleting a Sheet based on one row of information

    Hi All, I have a tab (scheduled days to work) where I put in a persons name and what days of the week they say they want to work. What i want to do is once the data is put in like the first table below a button is pressed and it will automatically populate a whole new tab for the times they...
  12. C

    Guess my number game in VBA - incorrect response to higher value input for first answer

    Hello! I am just working through making this (primarily for fun) and have encountered a weird error - this is a guess the random number game. The code generates a random number & assigns it to the variable myNumber. The user is prompted to guess the number & their guess is assigned to the...
  13. R

    Decreasing Do Until loop

    Hi guys, I'm pretty new to coding but I need it for a dissertation on auctions. Any help is greatly appreciated!! A simplified version of what I am trying to achieve is to have a blank excel file with the number 10 in A1. I then want to run a Do Until loop with "A1 - 1" until it gets to zero...
  14. M

    If Statement Kills the Do Loop

    I am trying to loop through data with the same if statement but once the if statement is fulfilled the first time the loop no longer calls the if statement for some reason, can someone please help? here is my code: *Row = 6 at this point Do Until Row = 36 If ActiveSheet.Cells(Row...
  15. A

    Getting .Find Method to stop at bottom of range (NOT loop around)

    Hi all, Thanks for all of the help previously. Here's a problem I'm having: I am using the .find method in a Do...While Loop to find duplicate values, but I want the loop to stop when it gets to the bottom of the range, not wrap around and search from the top (another way to put it would be...
  16. S

    Combine multiple sheets with same name from seperate wbs in a folder into one workbook

    Hello All, I want to combine a specific tab ("Summation") in all workbooks in a folder to a single workbook. I have my macro asking for the file path, a file name pattern and the tab name from each workbook. The only 2 I really need are the file path and the tab name but the middle is just...
  17. C

    VBA - Loop through list, copy/paste from 1st to 2nd sheet, copy/paste output from 2nd to 3rd sheet

    Summary Problem: I need to loop through a company list, copy a company from said list, one at a time, from first to second sheet, then copy a range output from the second sheet to a third sheet. I need that output that is pasted on the third sheet to be pasted moving down every third row (also...
  18. B

    Do Whie Loop to Add Days to Date

    Hello all, I am trying to create a function that would allow me to select a date cell and add a certain amount of days to it until it is larger than the current date. I keep crashing excle with the function below any suggestions? Seems like I am declaring the variables incorrectly. Public...
  19. N

    Do Until Loop, Loop help please

    I am trying to run a ‘Do Until’ loop in my macro that will search for a word, if its found, select the whole row containing that word, delete it, find the next and repeat. So far I have:</SPAN></SPAN> Do</SPAN></SPAN> Cells.Find(What:="Find_Word", After:=ActiveCell, LookIn:=xlFormulas...
  20. S

    What is wrong with this Do Until Loop? (simple)

    Thanks in advance for the time. I'm trying to set a Do Until loop and after the range sets, VBA just skips the loop. I want a macro that hides all "0" value columns. What's actually in the loop can be wrong as well, but I just want to know why VBA skips the loop. My logic is that the range is...

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