How to start IE in private mode in c# with selenium webdriver

后端 未结 1 1350
一整个雨季
一整个雨季 2020-12-11 11:34

I\'m starting using selenium Webdriver with c# and Visualstudio.

I would like to start Internetexplorer in private mode. So I have not to care about old browsing da

相关标签:
1条回答
  • 2020-12-11 12:33

    Here, InternetExplorerOptions Members page; it is stated that BrowserCommandLineArguments property only has an effect when the ForceCreateProcessApi is true. ForceCreateProcessApi default value is false.

    Would you please try to set it manually?

    options.ForceCreateProcessApi = true;
    options.BrowserCommandLineArguments = "-private";
    
    0 讨论(0)
提交回复
热议问题