I am trying to save the text file in this path:\"C:\\Test\\test.txt\" and when the file is already opened I need to check whether the file is opened and I need to close it b
If File.Exists("File1.txt") = False Then
File.CreateText("File1.txt").Close()
Else
Exit Sub
End If
If File.Exists("File2.txt") = False Then
File.CreateText("File2.txt").Close()
Else
Exit Sub
End If
End If