Q:

Unable to launch Chrome in remote webdriver

I have tried the following three options . I am using C#
DesiredCapabilities capabilities = DesiredCapabilities.Chrome();
capabilities.SetCapability("chrome.binary", "pathtogooglechrome\chromedriver.exe");
_remoteWebDriver = new ScreenShotRemoteWebDriver(new Uri("http://127.0.0.1:4444/wd/hub"),
                    capabilities);

or 
ChromeOptions options = new ChromeOptions();
options.BinaryLocation = "pathtogooglechrome\chromedriver.exe";
capabilities.SetCapability(ChromeOptions.Capability, options);
_remoteWebDriver = new ScreenShotRemoteWebDriver(new Uri("http://127.0.0.1:4444/wd/hub"),
                    capabilities);

or 
System.Environment.SetEnvironmentVariable("webdriver.chrome.driver", "pathtogooglechrome\chromedriver.exe");
_remoteWebDriver = new RemoteWebDriver(new Uri("http://127.0.0.1:4444/wd/hub"),
                  DesiredCapabilities.Chrome());

After the SetEnviromentVariable if i try the following code i get path of the ChromeDriver.exe
string temp = System.Environment.GetEnvironmentVariable("webdriver.chrome.driver");

I always get the same error System.InvalidOperationException : The path to the driver executable must be set by the webdriver.chrome.driver system property
I want know what i am doing wrong here, why path is not accepted?
Thank you in advance!
If any alternative solution is available please let me know.

A:

From documentation:
BinaryLocation  
Gets or sets the location of the Chrome browser's binary executable file.

So the above excerpt plainly says that the BinaryLocation is the path for chrome.exe and not chromedriver.exe.
And chromedriver.exe path should be defined in the PATH environment variable. 
So in your case the correct line would be:
options.BinaryLocation = @"pathtogooglechrome\chrome.exe"

Notice the @ in C# that will let you put un-escaped characters. Otherwise you would have needed \\ instead of \ etc. 

