I'm making a application which will search a text file for a specific string, each line has 1 word, no spaces. I can't seem to get it to display anything while its searching, other then the progress in the progress bar, and if you minimize it while its searching and bring it back up it will only refresh the progress bar.
Can anyone help me?
Here is the code:
Thanks in advance for the help.
Can anyone help me?
Here is the code:
VB.NET:
Private Sub Button2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button2.Click
If PswFile = Nothing Then Exit Sub
Password = txtPassword.Text
Dim FileContents() As String = IO.File.ReadAllLines(PswFile)
lblUsrBorder.Focus()
pgbrProgress.Value = 0
pgbrProgress.Maximum = FileContents.Length
For I = 0 To FileContents.Length - 1
pgbrProgress.Value += 1
tsslStatus.Text = "Processing Password: " & Format(pgbrProgress.Value / pgbrProgress.Maximum, "#0%")
Dim LineParts() As String = FileContents(I).Split("'")
If LineParts(0) = Password Then
tsslStatus.Text = "PASSWORD FOUND! #" & I & "(of " & FileContents.Length & ")"
fwFlash.FlashWindow(Me, FlashWindow.enuFlashOptions.FLASHW_ALL, 9999)
Exit Sub
End If
Next
fwFlash.FlashWindow(Me, FlashWindow.enuFlashOptions.FLASHW_ALL)
End Sub
Thanks in advance for the help.