How to disbale javacript alert in chrome browser | Selenium C# Forum
V
Vikas S Posted on 04/03/2019

Hi Gunjan,

 

I just googled regarding above mentioned question. So i am not able to find suitable answer anywhere please help me regarding how to disable the javscript alert in chrome browser. please find the attached screenshot.


G
gunjan Replied on 05/03/2019

This is a web notification. Try handling it with ChromeOptions class

ChromeOptions options= new ChromeOptions();

options.addArguments("--disable-notifications");

IWebDriver driver=new ChromeDriver(options);


V
Vikas S Replied on 05/03/2019

Ok thanks Gunjan.