A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Dates and times



 
 
Thread Tools Display Modes
  #1  
Old January 3rd, 2009, 01:28 PM posted to microsoft.public.access.gettingstarted
The Bhoy
external usenet poster
 
Posts: 3
Default Dates and times

I would like to calculate the hours and minutes between 2 dates and times i.e.
Friday 2nd January 2009 10:00 and Saturday 3rd January 2009 18:34.

I know the answer will be 32:34, but I need to put that into a formula for
access.

Also, (sorry) how do I write an expression for the input mask for the field
to show the date and time i.e. 02/01/09 10:00?

Kind regards
Brian
  #2  
Old January 3rd, 2009, 04:15 PM posted to microsoft.public.access.gettingstarted
Wayne-I-M
external usenet poster
 
Posts: 3,674
Default Dates and times

I would like to calculate the hours and minutes between 2 dates and times
i.e.
Friday 2nd January 2009 10:00 and Saturday 3rd January 2009 18:34.

I know the answer will be 32:34, but I need to put that into a formula for
access.


Try this
http://office.microsoft.com/en-us/ac...CL100570041033



Also, (sorry) how do I write an expression for the input mask for the field
to show the date and time i.e. 02/01/09 10:00?


FullTime: Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm")

--
Wayne
Trentino, Italia.


  #3  
Old January 3rd, 2009, 04:33 PM posted to microsoft.public.access.gettingstarted
The Bhoy
external usenet poster
 
Posts: 3
Default Dates and times

Hi Wayne

Thanks for your answer, I'm grateful.

On the second part you replied to: FullTime:
Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm") Can this be adapted to
be input in the 24 hour format, i.e. 18:40 instead of 6:30PM?

Kind regards
Brian

"Wayne-I-M" wrote:

I would like to calculate the hours and minutes between 2 dates and times

i.e.
Friday 2nd January 2009 10:00 and Saturday 3rd January 2009 18:34.

I know the answer will be 32:34, but I need to put that into a formula for
access.


Try this
http://office.microsoft.com/en-us/ac...CL100570041033



Also, (sorry) how do I write an expression for the input mask for the field
to show the date and time i.e. 02/01/09 10:00?


FullTime: Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm")

--
Wayne
Trentino, Italia.


  #4  
Old January 3rd, 2009, 04:46 PM posted to microsoft.public.access.gettingstarted
Wayne-I-M
external usenet poster
 
Posts: 3,674
Default Dates and times

I think you may be confused about what you input and what is really in the DB

You can set the Input mask (to short time) to give you 18:30
And you can set the field format to this as well
But this is not what is stored
You store the full time date value in any time date field - even if you
can't see it.

Just play around with the format property of the field until you are happy
with the result and then set the input mask to the same.

--
Wayne
Trentino, Italia.



"The Bhoy" wrote:

Hi Wayne

Thanks for your answer, I'm grateful.

On the second part you replied to: FullTime:
Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm") Can this be adapted to
be input in the 24 hour format, i.e. 18:40 instead of 6:30PM?

Kind regards
Brian

"Wayne-I-M" wrote:

I would like to calculate the hours and minutes between 2 dates and times

i.e.
Friday 2nd January 2009 10:00 and Saturday 3rd January 2009 18:34.

I know the answer will be 32:34, but I need to put that into a formula for
access.


Try this
http://office.microsoft.com/en-us/ac...CL100570041033



Also, (sorry) how do I write an expression for the input mask for the field
to show the date and time i.e. 02/01/09 10:00?


FullTime: Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm")

--
Wayne
Trentino, Italia.


  #5  
Old January 3rd, 2009, 05:18 PM posted to microsoft.public.access.gettingstarted
The Bhoy
external usenet poster
 
Posts: 3
Default Dates and times

Hi Wayne

Thanks for your advice, I've been using Office since it started and this is
my first venture into Access.

Kind regards
Brian

"Wayne-I-M" wrote:

I think you may be confused about what you input and what is really in the DB

You can set the Input mask (to short time) to give you 18:30
And you can set the field format to this as well
But this is not what is stored
You store the full time date value in any time date field - even if you
can't see it.

Just play around with the format property of the field until you are happy
with the result and then set the input mask to the same.

--
Wayne
Trentino, Italia.



"The Bhoy" wrote:

Hi Wayne

Thanks for your answer, I'm grateful.

On the second part you replied to: FullTime:
Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm") Can this be adapted to
be input in the 24 hour format, i.e. 18:40 instead of 6:30PM?

Kind regards
Brian

"Wayne-I-M" wrote:

I would like to calculate the hours and minutes between 2 dates and times
i.e.
Friday 2nd January 2009 10:00 and Saturday 3rd January 2009 18:34.

I know the answer will be 32:34, but I need to put that into a formula for
access.

Try this
http://office.microsoft.com/en-us/ac...CL100570041033



Also, (sorry) how do I write an expression for the input mask for the field
to show the date and time i.e. 02/01/09 10:00?

FullTime: Format([TableName]![TimeField],"dd/mm/yy hh:nn am/pm")

--
Wayne
Trentino, Italia.


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:58 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.