Hello,
I am trying to develop a loop that I can use to search a list that is dynamic in length and find a "start" point and an "end" point and then take that data and copy it to another sheet. The length of the data will change depending on the time of day. The list is composed of times in the first column and other data in the other columns. At different times of the day, the list will be longer than others. For example, if the report is ran at 9:00AM, then the times of 00:00 through 8:59 will be displayed and if the report was ran at 17:30 then 00:00 through 17:29 will be displayed. Now in a list of data there are multiple reports so there may be four different reports going from 00:00 to 17:30. This entire raw report will be pasted in a sheet by itself and I need the algorithm to get the data from the first list and I can figure out the rest. I need the loop to go to the first 00:00 in the list and then somehow find the last line of data for that individual time frame report. The only way I can think of (since there are no delimiters) is to tell it to go to the next 00:00 and move up one row, which would be the last line of data for the current set. Once this range is found I need the range to be copied to sheet X. I am assuming I would need a For Each loop, but how would I set it up? I'm sure it's relatively easy, but right now it has blown my mind.
Thanks for your help,
David B.
I am trying to develop a loop that I can use to search a list that is dynamic in length and find a "start" point and an "end" point and then take that data and copy it to another sheet. The length of the data will change depending on the time of day. The list is composed of times in the first column and other data in the other columns. At different times of the day, the list will be longer than others. For example, if the report is ran at 9:00AM, then the times of 00:00 through 8:59 will be displayed and if the report was ran at 17:30 then 00:00 through 17:29 will be displayed. Now in a list of data there are multiple reports so there may be four different reports going from 00:00 to 17:30. This entire raw report will be pasted in a sheet by itself and I need the algorithm to get the data from the first list and I can figure out the rest. I need the loop to go to the first 00:00 in the list and then somehow find the last line of data for that individual time frame report. The only way I can think of (since there are no delimiters) is to tell it to go to the next 00:00 and move up one row, which would be the last line of data for the current set. Once this range is found I need the range to be copied to sheet X. I am assuming I would need a For Each loop, but how would I set it up? I'm sure it's relatively easy, but right now it has blown my mind.
Thanks for your help,
David B.