Hi James,
The syntax is correct. Here's an idea: If any record has a blank in the name field it will cause it to bomb. Have any blanks?
>This code stops at the copy line as the syntax must not be right. Can anyone see what I'm doing wrong, I've tried every variation I could think of with no luck.
>
>***COMBINE.PRG
>SET EXACT OFF
>CLEAR
>CLOSE DATA
>SELECT A
>USE VV ORDER DAM1
>SELECT B
>USE AHORSE ORDER NAME
>SELECT A
>LOCATE
>SCAN
>STORE DAM1 TO MDAM1
>SELECT B
>SEEK MDAM1
>DO WHILE NAME = MDAM1
>STORE NAME TO cname
>***code bombs on copy
>COPY FILE &cname TO C:\JUNK\pedigrees\&cname
>SKIP
>ENDDO
>SELECT A
>ENDSCAN
>CLOSE DATA
>RETURN
>
>
>
>Thanks,
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05