473,403 Members | 2,293 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,403 software developers and data experts.

adding time

14
hello everyone, i have a problem that is probably simple to you to figure out. im using access 07 and novice as hell. I recently created a database form so that i can calculate my non-revenue miles for this transportation service im employed, unfortuntaly those particular hour i dont get paid for. Anyway i created a simple time sheet using military time. example. clock in time 13:00 til 15:00 which is 2 hours worked, but how can i get access to do that. i created an query. the expression is Totalhours:[timeend]-[timestart]= still nothing. can someone help me pls.
Dec 7 '11 #1

✓ answered by ADezii

Expand|Select|Wrap|Line Numbers
  1. TotalHours:DateDiff("h",[TimeStart],[TimeEnd])

7 3412
patjones
931 Expert 512MB
Is the total hours calculation being done in another text box on the same form? Also, where exactly are you writing out the expression to do the subtraction? Generally, calculated controls need to have the expression put in the Control Source setting in the property sheet.

Pat
Dec 7 '11 #2
ADezii
8,834 Expert 8TB
Expand|Select|Wrap|Line Numbers
  1. TotalHours:DateDiff("h",[TimeStart],[TimeEnd])
Dec 7 '11 #3
jawbone
14
can i email you guys my dbf so you can see my problem, sorry im so dumbfounded.
Dec 8 '11 #4
ADezii
8,834 Expert 8TB
@jawbone:
Attach you Database to another Post.
Dec 8 '11 #5
NeoPa
32,556 Expert Mod 16PB
How are [TimeEnd] and [TimeStart] defined? If they are both DateTime variables then what you have should already work. Why do you think it isn't? What are you seeing? We cannot help you unless you express the question clearly and keep us fully informed (as we can't see what you're doing - we rely on your question and explanation).
Dec 9 '11 #6
jawbone
14
thanks NeoPa i change my datatype to DateTime instead of text and it calculated fine. Thanks for your time everyone.
Dec 9 '11 #7
NeoPa
32,556 Expert Mod 16PB
That would certainly explain it.

You may want to select a post here as Best Answer before you go.
Dec 9 '11 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Nicolas Mejia | last post by:
Hello: I´m not a professional programer in Access. I´m working in a proyect that will permit me add my flight time, but I have been having problems with the time adding. Please can some one...
2
by: Bob W | last post by:
I am trying to get a total for times, but I am having trouble getting anything to work. Basically I created a query to pull up several people's name that performed certain details and how long each...
22
by: Drum2001 | last post by:
I have a table that tracks employee times. I have a column (Date/Time). Users, through a form, enter how long it takes them to complete a task. For example, 03:45 = 3 hours and 45 mins. I am...
3
by: pburling | last post by:
I have been reading the posts regarding the CompactDatabase method and would like to say Thanks to everyone, especially Mr.Steele. I have taken his advice and make a backup from the Backend before...
6
by: madbrit | last post by:
I am designing a wages calculator based on time started, and time finished., the total time will be about 3-400 hours a month. how can I add time together to be over 24 hours, Saple code below...
8
by: =?Utf-8?B?UGF1bA==?= | last post by:
Hi just wondering if anyone had any ideas on how to do this in C#. I am trying to get the total time of several start and stop time data entries. For example the input data looks like starttime...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.