RENAMING FOLDER:
Hi I use this code below to rename a file:

Dim aName As String
aName = InputBox("Rename file", "Type new file name")

Dim NewName As String, OldName As String

NewName = aName 'new
OldName = Dir1.List(Dir1.ListIndex) & "\" & File1.FileName 'old
FirstOccurrence = InStrRev(OldName, "\")
NewName = Left(OldName, FirstOccurrence) & NewName 'overwrite
Name OldName As NewName 'change
Dir1.Refresh

But my problem, is there extension name. Like for example, I am going to rename a file with the extension name of ".doc", what code should I write, if I ever type the" .doc " or not to the new filename, automatically it will save the file wih the extension name of ".doc"
Help me please??