Re: [Emerald] date format in CR6 formulas

Dale E. Reed Jr. ( (no email) )
Sat, 24 Apr 1999 11:23:32 -0700

Josh Hillman wrote:
>
> Our Emerald Invoice.rpt file has a couple formulas in it that display a few
> dates along with some text. At the moment the invoices will only display
> those dates in the form m/d/yy unless the date format in the Regional
> Settings of the Control Panel are changed to m/d/yyyy. Is there a way in
> CR6 to force dates (as part of formulas) to display as m/d/yyyy without
> depending on the Regional Settings values for the particular client machine?
> I already took care of simple date fields in the report and they display as
> m/d/yyyy without changing the Regional Settings, but I can't figure out why
> the formula dates only change when the Regional Settings format changes.
> Here's an example formula:
> "Billing / Service period: " + ToText({Invoices.StartDate}) + " - " +
> ToText({Invoices.EndDate})
>
> Before changing the regional settings, it outputs like:
> Billing / Service period: 12/1/98 - 1/1/99
> After changing the Regional Settings, it outputs like:
> Billing / Service period: 12/1/1998 - 1/1/1999
>
> I don't want the date format (in formulas) on the invoices to be dependent
> on what settings the Emerald client computer happens to have set.

Check out the Format() function. You should be able to use it in place
of
ToText() to format the date to your requirements.

-- 

Dale E. Reed Jr. Emerald and RadiusNT__________________________________________IEA Software, Inc. www.iea-software.com