LotusScript- copy file

zhaozj2021-02-16  96

Function copyFile (Byval sSource As String, Byval sDestination As String, Byval bOverWrite As Integer) As Integer On Error Resume Next copyFile = False If isFile (sSource) Then If bOverWrite Or (Not isFile (sDestination)) Then Filecopy sSource, sDestination If isFile (SDESTINATION) THEN COPYFILE = True End If End IFEND Function

example:

If CopyFile ("C: /Temp/temp.doc", "C: /Documents/temp.doc") THEN MSGBOX "File C: /Temp/temp.doc WAS Copied successful." Else Msgbox "File C: / Temp /TEMP.DOC WAS NOT COPIED. "END IF

转载请注明原文地址:https://www.9cbs.com/read-14261.html

New Post(0)