by Karthikeyan (187 Submissions)
Category: Windows API Call/Explanation
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Fri 15th December 2000
Date Added: Mon 8th February 2021
Rating: (1 Votes)
Move a file using MoveFile API
Dim retval As Long ' return value
retval = MoveFile("D:\showagent.txt", "D:\showagent1.txt")
If retval = 0 Then
MsgBox "File not found"
Else
MsgBox "File Move successful"
End If
End
End Sub