Created
November 16, 2019 15:57
-
-
Save issam1975/092de87ded54c1ffd8e1419a37075e61 to your computer and use it in GitHub Desktop.
selenium profile 2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ffoptions = new FirefoxOptions(); | |
ffoptions.AddArgument("--allow-file-access-from-files"); | |
ffoptions.AddArgument("--enable-local-file-accesses "); | |
ffoptions.SetPreference("browser.startup.homepage", "abcd"); | |
ffoptions.SetPreference("startup.homepage_welcome_url", "abcd"); | |
ffoptions.AddArguments("-profile", "C:/Users/issam/AppData/Roaming/Mozilla/Firefox/Profiles/4bge70ai.default-releaseGGG"); | |
var driverpath = AppDomain.CurrentDomain.BaseDirectory; | |
using (FirefoxDriver driver = new FirefoxDriver(FirefoxDriverService.CreateDefaultService(driverpath), ffoptions, TimeSpan.FromSeconds(240))) | |
{ | |
driver.Quit(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment