I want the user to input a value of how many times they want the word false to be written a certain column. Here is my code so far. I need the variable to correlate with a certain row in a column. If the person needs the word "False" written 545 times in column 12, the loop would no which row to stop at. I am trying to create an input box and here is my code. I am using excel 2013 in compatibility mode for 2003-2007. The client still uses excel 2003. The only time I am able to get the false string to populate the column is with this code:
Sheets("Sheet2").Cells(1, 12).Value = "Consolidation"
j = 2
Do Until Sheets("Sheet2").Cells(j, 12) = " "
Sheets("Sheet2").Cells(j, 12).Value = "FALSE"
j = j + 1
Loop
The first row has to be populated with the word "Consolidation". That piece of code works. This code obviously causes a buffer overflow. When I use this code to try and stop the "false" message at row 545, the value does not get written at all to the column
j = 2
Do Until Sheets("Sheet2").Cells(j, 12) = Sheets("Sheet2").Cells(545, 12)
Sheets("Sheet2").Cells(j, 12).Value = "FALSE"
j = j + 1
Loop
What code do I need to use in order to get input variable to equal to a row in column 12 and stop the message. I figure I could create integer variable and put in where it says .Cells(number,12) from the input but I think it still would not write the "false" message to the input row. Thanks
Bookmarks