本文整理匯總了VB.NET中System.Windows.Forms.HtmlWindow.Close方法的典型用法代碼示例。如果您正苦於以下問題:VB.NET HtmlWindow.Close方法的具體用法?VB.NET HtmlWindow.Close怎麽用?VB.NET HtmlWindow.Close使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類System.Windows.Forms.HtmlWindow
的用法示例。
在下文中一共展示了HtmlWindow.Close方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的VB.NET代碼示例。
示例1: If
Dim BalanceWindow As HtmlWindow
Private Sub BalanceWindowButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BalanceWindowButton.Click
If (WebBrowser1.Document IsNot Nothing) Then
With WebBrowser1.Document
BalanceWindow = .Window.OpenNew(New Uri("http://www.adatum.com/viewBalances.aspx"), "dialogHeight: 250px; dialogWidth: 300px; " & _
" dialogTop: 300px; dialogLeft: 300px; edge: Sunken; center: Yes; help: Yes; " & _
"resizable: No; status: No;")
' Listen for activity on the document.
WindowTimeout.Interval = 300000
WindowTimeout.Start()
End With
End If
End Sub
Private Sub Document_Click(ByVal sender As Object, ByVal e As System.EventArgs)
WindowTimeout.Stop()
WindowTimeout.Start()
End Sub
Private Sub WindowTimeout_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles WindowTimeout.Tick
If (Not BalanceWindow.IsClosed) Then
BalanceWindow.Close()
WindowTimeout.Stop()
End If
End Sub