Name Statement

किसी मौजूदा फ़ाइल या डिरेक्ट्री का नाम बदलता है.

Syntax:

Name OldName As String As NewName As String

पैरामीटर

OldName, NewName: Any string expression that specifies the file name, including the path. You can also use URL notation.

उदाहरण:

Sub ExampleReName

On Error GoTo Error

FileCopy "c:\autoexec.bat", "c:\temp\autoexec.sav"

Name "c:\temp\autoexec.sav" As "c:\temp\autoexec.bat"

End

Error:

If err = 58 Then

    msgbox "फ़ाइल पहले ही मौज़ूद है"

End If

End

End Sub