Put SET SAFETY OFF in the beginning of your procedure.
>Hi,
>
>I am using the code below to copy files to lcSourceFolder from lcPath.
>The problem is I get a message to overwrite files for every file. How can I avoid or say yes just once.
>
>
>Local lcPath
>If Version(2) = 2
> lcPath = Justpath(Sys(16, 0))
> If Atc('PROCEDURE', lcPath) > 0
> lcPath = Substr(lcPath, Rat(':', lcPath) - 1)
> Endif Atc('PROCEDURE', lcPath) > 0
>Else
> lcPath = Addbs(Justpath(_vfp.ServerName))
>Endif Version(2) = 2
>*return lcPath
>
>lcSourceFolder = Thisformset.frmSecure.text2.Value
>
>Copy File (Addbs(lcSourceFolder) + "*.*") To (lcPath)
>
>
>Thanks
If it's not broken, fix it until it is.
My Blog