codigo2
codigo2
RowCount = 0 Then
MessageBox.Show("the datagridview is emptly")
Else
If Directory.Exists("C:\Foldertxt") = False Then
Directory.CreateDirectory("C:\Foldertxt")
End If
Dim sFile As String = "C:\Foldertxt\file.txt"
While File.Exists(newFullPath)
Dim tempFileName As String = String.Format("{0}({1})", fileNameOnly,
System.Math.Max(System.Threading.Interlocked.Increment(count),count - 1))
newFullPath = Path.Combine(path__1, tempFileName & extension)
End While
f.WriteLine(row)
MessageBox.Show("file created")
End Using
End If