date format spacing
date format spacing
(OP)
Hi!
I'm using the date format 12 31 2022. No separator. How am I going to put space between month, day and year in digits? Example, 1 2 3 1 2 0 2 2.
Thank you.
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS Contact USThanks. We have received your request and will respond promptly. Come Join Us!Are you a
Computer / IT professional? Join Tek-Tips Forums!
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail. Posting Guidelines |
|
Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.
Here's Why Members Love Tek-Tips Forums:
Register now while it's still free!
Already a member? Close this window and log in.
RE: date format spacing
CODE
If the field you are working with is not a date field, the approach will need to change. Please let us know how you go.
Regards,
Pete.
RE: date format spacing
with error "bad number format string". then this was highlited.
whilePrintingRecords;
Local StringVar a := ToText({ARRFH.DOCDATE},'MM dd yyyy');
Local Numbervar b :=Len(a);
Local Numbervar i;
Local Stringvar RESULT := ' ';
for i := 1 to b Step 1 do
RESULT := RESULT + mid(a, i,1) + ' ';
replace (RESULT, ' ', ' ')
RE: date format spacing
Try this:
CODE
Cheers,
Pete.
RE: date format spacing
Hi! I added pwformatdate and it worked!! thank you so much.
whilePrintingRecords;
Local StringVar a := ToText(pwformatdate({ARRFH.DOCDATE}),'MM dd yyyy');
Local Numbervar b :=Len(a);
Local Numbervar i;
Local Stringvar RESULT := ' ';
for i := 1 to b Step 1 do
RESULT := RESULT + mid(a, i,1) + ' ';
replace (RESULT, ' ', ' ')