Visual Basic Help ?
Hello everyone. It great to be back on here. Please can anyone help me with this code fragment below ? Its in Visual Basic and I need to produce a flowchart of how it works for my project. So basically describing the functionality. Its only a small fragment and i'm hopeless at doing them. Any pointers would help me out a bunch, like how to do them properly and how to detail each of the steps. I also need to discuss the strengths and weaknesses of the code. So talk about the choice of programming language for this program, it's structure and style maybe ? Any of your help would be greatly appreciated 1 Public Class Form1 2 Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click 3 Dim I As Integer 4 Dim F As Boolean 5 Dim Ch As String 6 Dim Len As Integer 7 Dim FileWrite As System.IO.StreamWriter 8 Len = TextBox1.Text.Length 9 Ch = TextBox1.Text.ToCharArray() 10 F = True 11 FileWrite = My.Computer.FileSystem.OpenTextFileWriter("file.txt", False) 12 For I = 0 To Len - 1 13 If Not (Char.IsLetter(Ch(I))) Then 14 F = False 15 End If 16 Next 17 If (F = False) Then 18 MsgBox("Not valid name") 19 End If 20 If (F = True) Then 21 MsgBox("Name ok") 22 FileWrite.WriteLine(Ch) 23 End If 24 FileWrite.Close() 25 End Sub 26 End Class