-1

Every time I execute application. ChromeDriver.exe gets execute. I simply wanna hide it while application gets executed. It should run in silent or headless mode. I have my code written in C# with selenium.

  • 2
    See: [How do I do X?](https://meta.stackoverflow.com/questions/253069/whats-the-appropriate-new-current-close-reason-for-how-do-i-do-x) The expectation on SO is that the user asking a question not only does research to answer their own question but also shares that research, code attempts, and results. This demonstrates that you’ve taken the time to try to help yourself, it saves us from reiterating obvious answers, and most of all it helps you get a more specific and relevant answer! See also: [ask] – JeffC Sep 27 '19 at 17:59

1 Answers1

0

When you initialize the ChromeDriver instance, you can add this:

var chromeOptions = new ChromeOptions();
chromeOptions.AddOption("--headless");

driver = new ChromeDriver(chromeOptions);

This will tell ChromeDriver to run without rendernig a browser.

CEH
  • 5,358
  • 2
  • 15
  • 36