Hi
I have below code . Video does not automatically get run. It opens but user has to click to start video
C#
{
vProcessId = Start("youtube.com/watch?v=MYojqnJ34g4");
}
public static int Start(string processName)
{
var process = Process.Start("chrome.exe", @processName);
return process.Id;
}Thanks

Vishal YelveRank #178 · 13.6K reputationPosted Dec 1, 2022, 2:32 AM EST
Hi Ramco,
Try this
class Program { static void Main(string[] args) { Console.WriteLine("Process Start!"); var _process = new ProcessStartInfo(@"C:\Program Files\Internet Explorer\iexplore.exe", "youtube.com/watch?v=MYojqnJ34g4?autoplay=1"); // to open in Chrome use uncomment below line //var _process = new ProcessStartInfo(@"C:\Program Files (x86)\Google\Chrome\Application\new_chrome.exe", "youtube.com/watch?v=MYojqnJ34g4?autoplay=1"); Process.Start(_process); } }Output