Good evening forumers,
I have been working (and been somewhat unsuccessful) on a macro that will remove the extra records from this data set. The records were recorded minute-by-minute, over a range of days, and I need to truncate the records so that each day only has hourly records remaining.
In the code below, there are a couple of loops, the first checks to see that the date on line x equals the date on line x + 1 --- i need this to catch when the date changes. My second loop takes the time and adds 60 minutes to it -- i need this to compare the time, as I am looking for my readings to be exactly 60 minutes from one another. In my last loop, I was trying to print a status of (greater than 60 minutes, less than 60 minutes, or equal to 60 minutes, with the last being the one I am interested in.
Then, my hope was to be able to filter out what i dont want and delete, leaving only readings that are 60 minutes from one another, for each day given.
My first 2 loops do what I want, but i cant get the last one to work. Here is what I have come up with codewise, and I have attached a small data sample.
I realize that my last loop is no where near where it needs to be, so any form of help or thoughts on another approach would be awesome.
Much thanks in advance,
wherbjr35
Bookmarks