 | HostOpenBrowser Method (String, String, String, Boolean, Boolean, Boolean, Boolean, Boolean, Boolean, Boolean, Boolean) |
Opens a web page in the specified browser.
Namespace:
Ranorex
Assembly:
Ranorex.Core (in Ranorex.Core.dll) Version: 12.7.4-git.38314c06
Syntaxpublic int OpenBrowser(
string url,
string browserName,
string browserArgs,
bool killExisting,
bool maximized,
bool clearCache,
bool clearCodeCache,
bool clearServiceWorker,
bool incognitoMode,
bool clearCookies,
bool instrument
)
Public Function OpenBrowser (
url As String,
browserName As String,
browserArgs As String,
killExisting As Boolean,
maximized As Boolean,
clearCache As Boolean,
clearCodeCache As Boolean,
clearServiceWorker As Boolean,
incognitoMode As Boolean,
clearCookies As Boolean,
instrument As Boolean
) As Integer
Parameters
- url
- Type: SystemString
The URL of the web page to open. - browserName
- Type: SystemString
The name of the browser to open. Can either be "firefox", "ie", "chrome", "chromium", "edge" or "edgechromium". - browserArgs
- Type: SystemString
Additional command line arguments to pass to the browser. - killExisting
- Type: SystemBoolean
Specifies whether any running browser instances should be closed first. - maximized
- Type: SystemBoolean
Specifies whether the started browser instances should be started maximized. - clearCache
- Type: SystemBoolean
Specifies whether cache should be cleared on browser start. - clearCodeCache
- Type: SystemBoolean
Specifies whether code cache should be cleared on browser start. - clearServiceWorker
- Type: SystemBoolean
Specifies whether Service Worker folder should be cleared on browser start. - incognitoMode
- Type: SystemBoolean
Specifies whether the browser should start in incognito mode - clearCookies
- Type: SystemBoolean
Specifies whether cookies should be deleted on browser start. - instrument
- Type: SystemBoolean
Specifies whether the browser should be instrumented before browser start.
Return Value
Type:
Int32The process ID of the browser.
Implements
IHostOpenBrowser(String, String, String, Boolean, Boolean, Boolean, Boolean, Boolean, Boolean, Boolean, Boolean)
See Also