Hello
I am using WebBrowser Control inside windows form
I am using Webbrowser1.navigate(filepath) code many times.
User inputs part of pdf filename and I add extension. After that I an searching in our network and load it in case it was found.
It's happened on close of application(Application.Exit action) after user many time uses this search
Here is the code:
Private
Sub btnSearchJob_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSearchJob.Click
WebBrowser1.Navigate(
"about:blank")
Dim JobNumber As String = Me.txtJobNumber.Text.Trim
Try
Dim filePath As String = getFileLocation(JobNumber & ".pdf")
If Not String.IsNullOrEmpty(filePath) Then
WebBrowser1.Navigate(filePath)
Else
ShowMessage(
"Such number does not exist")
End If
Catch ex As Exception
End Try
Michael