Print without showing Print Preview on chrome

Viewed 43

I found a way to print without showing Print Preview on chrome like this video https://www.youtube.com/watch?v=8dgzHO8A6PU, because then I can use AutoIT to install the printer but when I run Selenium it still shows the Print Preview window. So I want to ask when I run selenium to open chrome what file exactly am I working with? [enter image description here

[enter image description here

1 Answers
Dim cd As New ChromeDriver    
cd.AddArgument "--disable-print-preview"
cd.Start
cd.Get "https://www.google.com/"
cd.Window.Maximize
cd.ExecuteScript ("print()")

Thank @AbiSaran

Related