Hi Poppa Smurf,
I've been trying to follow along with all of this because I'm trying to accomplish pretty much the same thing, plus I'm also new to VBA.
I am creating an Access database based on an Excel spreadsheet.
One of the fields in the Excel spreadsheet is labeled [Trip Time](T).
This field is populated through a simple arithmatic formula that subtracts values from two previous fields, which are, [Start Time](R) & [End Time](S).
The format of those fields, [Start Time](R) & [End Time](S), is h.mm AM/PM
That formula that populates [Trip Time](T) reads (=Snn - Rnn) and the output format of that field is (Short Time) h.mm, for instance 2:30 (2 1/2 hours).
As I mentioned, I'm trying to apply what you've been telling Smithinator but I'm having some difficulties and I'd like to ask for your help as well.
If you will extend your help to me then here's where I'm at with all of this.
First, I'm running Windows 7 and working in Access 2007.
Now please correct me if I'm mistaken with any of the following, because I've come to understand that;
1. I need to create a Module (which will be my first).
2. The Raskews code deals with Dates as well as h.mm.ss AM/PM times.
3. Once the Module is created correctly it can then be used to populate the [Trip Time] field.
If these things are so then I'd like to ask your help with;
1. Creating a working Module that;
a. uses a single date - or using the same date twice. (because the Logs currently show all trips occuring on the same date)
b. that does not use Seconds (.ss) in the caculations
2. If necessary, how to tailor the Raskews code to work correctly with the existing labeled fields ([Date], [Start Time], [End Time], [Trip Time].
3. How and where to implement the Module so that the [Trip Time] field is populated in the Table, the Form and the Report.
(If only within the Form during data entry, then how can I make it so that the [Trip Time] field is also popualted within past, existing Log entries?)
With appreciation,
Charles