date switch/format

B

BJ

Is there a switch that can change a date format from "yyyymmdd" to "month
day, year"? An example of the data and what I would like it to look like
when it is printed: 20081125 to read November 25, 2008
 
M

macropod

Hi BJ,

Here's one way, using a set of nested fields coded as:
{QUOTE{={FILLIN "Input the Date in YYYYMMDD format."} \# "0000'-'00'-'00" } \@ "MMMM, D YYYY"}
After creating the field, select it & press F9. Then follow the prompt.

Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste
them from this message. If you press Ctrl-F9 three times, you'll get three nested fields (ie '{ { { } } }'), which you can the add
the text to as shown above.
 
B

BJ

How do I link that formula to a database so it changes with the records?

macropod said:
Hi BJ,

Here's one way, using a set of nested fields coded as:
{QUOTE{={FILLIN "Input the Date in YYYYMMDD format."} \# "0000'-'00'-'00" } \@ "MMMM, D YYYY"}
After creating the field, select it & press F9. Then follow the prompt.

Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste
them from this message. If you press Ctrl-F9 three times, you'll get three nested fields (ie '{ { { } } }'), which you can the add
the text to as shown above.

--
Cheers
macropod
[MVP - Microsoft Word]


BJ said:
Is there a switch that can change a date format from "yyyymmdd" to "month
day, year"? An example of the data and what I would like it to look like
when it is printed: 20081125 to read November 25, 2008
 
M

macropod

Hi BJ,

I take it this is for a mailmerge. You didn't mention that before. In that case you could use a field construction like:
{QUOTE{MERGEFIELD MyDate \# "0000'-'00'-'00" } \@ "MMMM, D YYYY"}
where 'MyDate' is the name of the date field in your database.

--
Cheers
macropod
[MVP - Microsoft Word]


BJ said:
How do I link that formula to a database so it changes with the records?

macropod said:
Hi BJ,

Here's one way, using a set of nested fields coded as:
{QUOTE{={FILLIN "Input the Date in YYYYMMDD format."} \# "0000'-'00'-'00" } \@ "MMMM, D YYYY"}
After creating the field, select it & press F9. Then follow the prompt.

Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste
them from this message. If you press Ctrl-F9 three times, you'll get three nested fields (ie '{ { { } } }'), which you can the
add
the text to as shown above.

--
Cheers
macropod
[MVP - Microsoft Word]


BJ said:
Is there a switch that can change a date format from "yyyymmdd" to "month
day, year"? An example of the data and what I would like it to look like
when it is printed: 20081125 to read November 25, 2008
 
B

BJ

Excellant.......thanks for your help, I appreciate it.

BJ

macropod said:
Hi BJ,

I take it this is for a mailmerge. You didn't mention that before. In that case you could use a field construction like:
{QUOTE{MERGEFIELD MyDate \# "0000'-'00'-'00" } \@ "MMMM, D YYYY"}
where 'MyDate' is the name of the date field in your database.

--
Cheers
macropod
[MVP - Microsoft Word]


BJ said:
How do I link that formula to a database so it changes with the records?

macropod said:
Hi BJ,

Here's one way, using a set of nested fields coded as:
{QUOTE{={FILLIN "Input the Date in YYYYMMDD format."} \# "0000'-'00'-'00" } \@ "MMMM, D YYYY"}
After creating the field, select it & press F9. Then follow the prompt.

Note: The field brace pairs (ie '{ }') for the above example are created via Ctrl-F9 - you can't simply type them or copy & paste
them from this message. If you press Ctrl-F9 three times, you'll get three nested fields (ie '{ { { } } }'), which you can the
add
the text to as shown above.

--
Cheers
macropod
[MVP - Microsoft Word]


Is there a switch that can change a date format from "yyyymmdd" to "month
day, year"? An example of the data and what I would like it to look like
when it is printed: 20081125 to read November 25, 2008
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top