I have a form with a textbox and I want that textbox to read from http.conf on line 162.
Line 162 reads ServerAdmin you@yourdomain.com
Shouldn’t this code work?
Public Class Form1
Dim apacheconf = "c:\httpd.conf"
Dim line() As String = IO.File.ReadAllLines(apacheconf)
Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
TextBox1.Text = line(59)
End Sub
End Class
Also when the textbox reads the line, it must only display the email address and not the word “ServerAdmin” How can I do that?