Also, I'm not sure if the syntax on the req_date = line is correct.
I think the best way to do it would be:
req_date = EVAL('THISFORM.t_req_date'+ALLT(STR(i))+'.Value')
and then just print DTOC(req_date) or TTOC (req_date) depending on your needs.
>Steve,
>If 't_req_date' is a DateTime field, then you need to use TTOC() not DTOC() to include the time.
>
>HTH
>Barbara
>
>>I keep an getting error or the wrong result when I run the following:
>>
>>FOR i = 1 TO 8
>> req_date = ('THISFORM.t_req_date'+ALLT(STR(i))+'.Value')
>> ? ' Requested Date/Time = ' + DTOC(&req_date)
>>ENDFOR
>>
>>I grab 8 date/times off of my form (out of textboxes) and print them to a file for printing. The "?" line prints a line for each date/time, but the date either prints without a time next to it or I get a syntax/run-time error. I have tried many variations, but I had it working once and then it has not worked since. Please help. Thanks very much.
--Todd Sherman
-Wake Up! Smell the Coffee!