PC Review


Reply
Thread Tools Rate Thread

Date format and Header information

 
 
=?Utf-8?B?UHVyZUV2aWw=?=
Guest
Posts: n/a
 
      6th Oct 2006
I've created a database to track timecards and I've run across two issues I
can't find an answer to:

How do I change the date format without using the presets. We work in
yyyy/mm/dd; also on one report I need to display mmm/dd. Neither of these
options appears in the presets.

I've added a date range requirement to a query, when the report is run the
user is prompted "start date: mm/dd/yy" then "end date: mm/dd/yy" (see above
note on changing the date format). I would like the date range selected to
appear in the report header as "Pay Period: YYYY/MM/DD to YYYY/MM/DD".
Suggestions?

Thanks!
Pamala
 
Reply With Quote
 
 
 
 
ruralguy via AccessMonster.com
Guest
Posts: n/a
 
      7th Oct 2006
The Format() function accepts almost *any* user defined format.
Format([YourDate],"yyyy/mm/dd") OR Format([Yourdate],"mmm/dd")

PureEvil wrote:
>I've created a database to track timecards and I've run across two issues I
>can't find an answer to:
>
>How do I change the date format without using the presets. We work in
>yyyy/mm/dd; also on one report I need to display mmm/dd. Neither of these
>options appears in the presets.
>
>I've added a date range requirement to a query, when the report is run the
>user is prompted "start date: mm/dd/yy" then "end date: mm/dd/yy" (see above
>note on changing the date format). I would like the date range selected to
>appear in the report header as "Pay Period: YYYY/MM/DD to YYYY/MM/DD".
>Suggestions?
>
>Thanks!
>Pamala


--
HTH - RuralGuy (RG for short) acXP WinXP Pro
Please post back to this forum so all may benefit.

Message posted via http://www.accessmonster.com

 
Reply With Quote
 
fredg
Guest
Posts: n/a
 
      7th Oct 2006
On Fri, 6 Oct 2006 15:26:02 -0700, PureEvil wrote:

> I've created a database to track timecards and I've run across two issues I
> can't find an answer to:
>
> How do I change the date format without using the presets. We work in
> yyyy/mm/dd; also on one report I need to display mmm/dd. Neither of these
> options appears in the presets.
>
> I've added a date range requirement to a query, when the report is run the
> user is prompted "start date: mm/dd/yy" then "end date: mm/dd/yy" (see above
> note on changing the date format). I would like the date range selected to
> appear in the report header as "Pay Period: YYYY/MM/DD to YYYY/MM/DD".
> Suggestions?
>
> Thanks!
> Pamala


In your query you must use the US date format of month/day/year (as
you already do) to enter the parameters.
However, you can display the date using your own format.
Add an unbound control to the report header.
Set it's control source to:

= "Pay Period: " & Format [start date: mm/dd/yy],"yyyy/mm/dd") & " to
" & Format [end date: mm/dd/yy],"yyyy/mm/dd")

The text within the brackets must be identical to the query bracketed
criteria text.
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
 
Reply With Quote
 
=?Utf-8?B?UHVyZUV2aWw=?=
Guest
Posts: n/a
 
      7th Oct 2006
Thanks! I accidentally posted this request three times because the site told
me there was an error and the post wasn't posted, but it actually was.
Several people made the same suggestion as you, but you were the only one
that pointed out the need to make the text within the brackets identical - I
kept getting an error message until I read your post and realized that I
didn't have colons in the query text.

Thanks for the help!

Pamala

"fredg" wrote:

> On Fri, 6 Oct 2006 15:26:02 -0700, PureEvil wrote:
>
> > I've created a database to track timecards and I've run across two issues I
> > can't find an answer to:
> >
> > How do I change the date format without using the presets. We work in
> > yyyy/mm/dd; also on one report I need to display mmm/dd. Neither of these
> > options appears in the presets.
> >
> > I've added a date range requirement to a query, when the report is run the
> > user is prompted "start date: mm/dd/yy" then "end date: mm/dd/yy" (see above
> > note on changing the date format). I would like the date range selected to
> > appear in the report header as "Pay Period: YYYY/MM/DD to YYYY/MM/DD".
> > Suggestions?
> >
> > Thanks!
> > Pamala

>
> In your query you must use the US date format of month/day/year (as
> you already do) to enter the parameters.
> However, you can display the date using your own format.
> Add an unbound control to the report header.
> Set it's control source to:
>
> = "Pay Period: " & Format [start date: mm/dd/yy],"yyyy/mm/dd") & " to
> " & Format [end date: mm/dd/yy],"yyyy/mm/dd")
>
> The text within the brackets must be identical to the query bracketed
> criteria text.
> --
> Fred
> Please respond only to this newsgroup.
> I do not reply to personal e-mail
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Format date in header Sammie Microsoft Excel Worksheet Functions 4 15th Jan 2010 07:16 PM
Date range in header and date format =?Utf-8?B?UHVyZUV2aWw=?= Microsoft Access 3 7th Oct 2006 06:17 AM
Changing the date format & adding the date range to the header =?Utf-8?B?UHVyZUV2aWw=?= Microsoft Access 1 6th Oct 2006 11:31 PM
HTML Print format in Outlook 2003 missing email header information =?Utf-8?B?Q2hyaXMgQ2Vl?= Microsoft Outlook Printing 0 13th Feb 2006 04:59 PM
Header date format Fernando Brines Aparisi Microsoft Windows 2000 Fax 1 18th Sep 2003 09:56 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:20 AM.