title: Selenium firefox profile update download directory after creating webdriver
body: <p>I'm wondering how can I update/change download location in selenium once I started driver? </p>
  
  <p>it is not problem to set download dir during creation of profile and initiation of webdriver. The problem appears after initiation of webdriver to change directory depending on data type.</p>
  
  <p>For example 
  -if dl doc is word save in Docs\Word
  -if dl doc is pdf save in Docs\pdf</p>
  
  <p>this is my code</p>
  
  <pre><code>profile = webdriver.FirefoxProfile()
  profile.set_preference('browser.download.dir', os.getcwd())
  profile.set_preference("browser.download.folderList", 2)
  profile.set_preference('browser.helperApps.neverAsk.saveToDisk', 'application/download,application/octet-stream,application/pdf')
  profile.update_preferences()
  driver = webdriver.Firefox(firefox_profile=profile)
  driver.delete_all_cookies()
  sleep(10)
  # this part doesn't work
  driver.profile.set_preference('browser.download.dir',"{0}\{1}".format(os.getcwd(),"Docs"))
  driver.profile.update_preferences()
  </code></pre>