do loop

  1. D

    Looping through excel files in a folder to find workbooks with locked VBA project modules

    Hi Folks, I am trying to build an excel model which will loop through all the workbooks in a folder and tell me which of them has password protected VBE modules. The reason for this requirement is that I'm trying to use another excel VBA model to find workbooks that are challenging our server...
  2. VBE313

    Exit Do Loop at Certain Cell?

    How do you exit a Do Loop at a certain cell?
  3. T

    Macro to loop through each row and create a 3d stacked bar graph per row

    Hi all, I have created my Do Loop to loop through my excel spreadsheet by row but I am stuck on creating a 3D stacked bar chart for each row, here is sample data Name Salary Bonus Other Chart a 50...
  4. O

    Populate a Variable size range with changing constants

    Below is an excerpt from a workbook I am attempting to build. I have been trying to automate the population of the correct range of rows in column F based on data input into columns B, C and D. The data in this example is manually entered to demonstrate my desired results. Knowing each row...
  5. L

    Using VBA to insert a dynamic variable formula ERROR

    Good afternoon, This is my first time posting a question on this thread but have seen many How To for my Excel projects. I've been using Excel for over 10+ years and VBA about 3 so it's not too often I come across something I cant figure out. I am trying to insert a variable formula nested...
  6. R

    Find last of multiple entries

    Do While ia < 16383 'limited to how many columns are available to be populated ActiveCell.Offset(0, 1).Select 'shift cell to seach If ActiveCell.Value = SN Then ia = ia + 1 'counter for columns Do While ib < 13...
  7. S

    Simple VBA Copy & Paste Loop

    Hi there MrExcel community, this is my first forum post! So I have just recently started a new job and blagged that I could do some basic VBA and ...well... let's just say that I am on a steep learning curve :) I have a basic repetitive task that I am hoping one of you could help me with. I've...
  8. H

    Do Until Loop Problem

    Hi everyone, See a snippet of my spreadsheet, showing rows and columns that contain data. Note that Data in the ranges B4:B7, E4:E7, B11:B14 and E11:E14 are merged. The Direct Labor for the first person should be 51+4+1 = 56 hr and 3197.18+250.76+62.69 = 3510.63 The Direct Labor for the first...
  9. S

    Do Loop with Countifs is not giving desired results in VBA

    Hi I have a code, which pulls data in few columns from a given data using RandBetween. To remove duplicates in column (except "X"), a code is given below: This code is not giving the desired results, that is it stops itself before checking for any duplicates. Kindly help in correction of this...
  10. M

    VBA Loop without DO Error.

    Heya, Excel is coming up with an error saying: "Loop without Do", while there is a Do statement in place (as per code below). Any tips? Effectively I want the DO Loop to run if the 2nd Cell in a row is empty for the intent to copy data into another worksheet, in addition it must skip over...
  11. A

    Highlighting only the 2nd+ instance of a duplicate in a range

    Hi again, Thank you to those heroes that helped me with my question earlier today, but I've got another one. I'm trying to get this macro to highlight ONLY the 2nd, 3rd, 4th etc instance of a duplicate. I've since reverted to the original formula, but adding in a For...Each counter didn't...
  12. K

    Wait until user navigates away from current internet explorer webpage THEN run VBA code

    Hello, I have a piece of code that opens a webpage in internet explorer. I then want the next section of the code (just picks information off the webpage referring to specific elements) to run only when 'the user' types in a search and navigates to the search results page. The program would...
  13. I

    Excel BA loop correction - Excel VBA

    I am trying to highlight certain cells based on it's column 4 values. Basically, If column 4 value is negative, then we search through the column 4 from the beginning and if there is positive match (That is positive of the column 4 value and then matching the respective column 3 and 6 values)...
  14. 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...
  15. myactiondesign

    User Exit Through Cancel or Close in FOR/DO LOOP

    Hi all, I've got a fully functioning macro that cycles through a range of cells and inserts user input sales data into each cell, one-by-one. The problem is that you cannot cancel or exit. Sub FirstSalesInput() 'This sub will create six messages boxes for user input 'The user input will be...
  16. V

    Help making a Do-While loop... Loop

    Hi all, I'm having trouble making this loop iterate: Do While Cells(96, DtlNxtCol + 2).Value > 0 Sheets("Detail_Sheet").Select Cells(10, DtlNxtCol).Copy Sheets("Summary").Select Cells(SumNxtRow, 1).Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone...
  17. E

    Using Loop in VBA to Delete a repeating selection of Rows

    Hi there!! I have a “soft copy” of an 80-page report that was downloaded from an older mainframe system. The soft copy was in a .txt format, and I imported it into Excel using fixed-width delimiters for the columns. Since the report is 80-pages, it translates to more than 1,700 rows of data in...
  18. D

    Checking if data exist in range, if it exist add up the number

    Hello Everyone, I'm pretty new to VBA and hope you can advise me in some coding which I'm currently stuck for days. I have 1 sheet (Sheet 2) which have a list of name, designation, department and hours. In another sheet (Sheet 2) I would like to run a summary of the total number hours in each...
  19. P

    DO loop with an IF statement

    Dear all, I am having an issue getting an IF statement to work inside a DO loop and I was wondering if you would be so kind as to give me some indication as to why it is not working. I have Microsoft Excel 2007 and Windows 7 Entreprise. In my Excel spreadsheet, I have in column B a list of...
  20. E

    Excel vba macro - Loop to format sheet

    Hi there!!</SPAN> I created a macro to automatically insert subtotals into a report. Now I want to include code that will format each subtotal row (bold, shaded). My idea is to have the macro search for “ Total” as a String and each time it finds that character string, format the row...

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