Hello
I am trying to make VBA to copy data from Excel to .txt file.
The problem is that I am not quite sure of 2 things
1) How to define the range so that VBA should know to take a specific range for each Car make (for the first Car make the range was initiated manually). So I think the condition would be something like: If(Car make==same as Car make from rows below), then do a minimum on Mileage for that range, and this should be done for each Car make.
.
2) How to make the code more efficient rather than declaring a lot of variables. As there would be hundreds of entries (multiple Car makes, and after each make the lowest Mileage should be displayed). As what has been done so far for rows 2-3 should also be done for rows 4-7, and so on... But for the sake of the example I kept it short.
Below you'll find attached the Workbook (the code is located in Module1), as well as the expected Answers in the .txt file.
I would be more than grateful if someone could help me out with it.
Many thanks, I appreciate it!
Gordon
Bookmarks