Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim strd As String = String.Empty For i = 0 To NumericUpDown1.Value - 1 strd &= TextBox1.Text & i & " , " Next strd = strd.Remove(strd.Length - 2, 2) My.Computer.FileSystem.WriteAllText(Application.StartupPath & "\Test.txt", strd, False) MsgBox("Done....") End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim strd As String = String.Empty For i = 0 To NumericUpDown1.Value - 1 strd &= TextBox1.Text & i & " , " Next strd = strd.Remove(strd.Length - 2, 2) My.Computer.FileSystem.WriteAllText(Application.StartupPath & "\Test.txt", strd, False) MsgBox("Done....") End Sub