>I have to to a 'Copy To' with sequential names, ie. "req001", "req002" etc.
>I can obviously just put a variable there because the file gets named with the variable.
>So, is there a way to do this?
Christopher,
You said sequential names. Is this done in a FOR...NEXT looping structure? If so, you could use the loop counter variable and a character variable to construct the name, rather than hard coding the sequential name.
As an example:
FOR lnLooper = 1 TO 10
lcLooper = PADL(ALLTRIM(STR(lnLooper)), 3, '0')
lcFile = 'req' + lcLooper
COPY TO (lcFile)
ENDFOR (or NEXT, whatever is your preference)
You can, of course, include the fully qualified path in the lcFile variable as well. You can even get the path from the user, if desired, and build the lcFile variable with that as a prefix.
Dana
Where's the damned Any Key?...too late