title: Selenium WebDriver file upload browse button c#
body: <p>I have problem with browse button and switching to file dialog. I cannot use my file path control and just send there my string with file path and file itself, as it's readonly and in fact some behind control is my input filepath.</p>
  
  <p>Here's my code</p>
  
  <pre><code>driver.FindElement(By.Id("browseButton")).Click();
  driver.SwitchTo().ActiveElement().SendKeys(filepath);
  </code></pre>
  
  <p>Above code fills my control for file path, as i can see that on UI. But my open file dialog is still opened and i do not know how to close it and submit my upload.</p>