Searching...
2:08 AM

Copy File

code:
Private Declare Function CopyFile Lib "Kernel32" Alias "CopyFileA" (ByVal lpExistingFileName As String, ByVal lpNewFileName As String, ByVal bFailIfExists As Long) As Long

Private Function CopyToFile(FileName As String, Newname As String) As Boolean
    hCopy = CopyFile(FileName, Newname, 0)
    If hCopy <> 0 Then
        CopyToFile = True 'success
    End If
End Function

0 comments:

Post a Comment

 
Back to top!