RSelenium, Chrome, How to set download directory, file download error
I ran into this same problem and here's the solution that worked:
For some reason, you need to use double backslashes in the download.default_directory path, rather than single forward slashes.
So try this:
"download.default_directory" = "C:\\\XXX\\\YYY"
Instead of this:
"download.default_directory" = "C:/XXX/YYY"
Problem downloading file from a new tab with Rselenium
I was able to download the excel file by,
library(RSelenium)
driver <- rsDriver(browser = c("chrome"), port = 4341L)
remDr <- driver$client
# Select the dropdown menu,
remDr$findElement(using = "xpath",'//*[@id="ReportViewer1_ctl05_ctl04_ctl00"]') -> dropdown
dropdown$clickElement()
# Select the Excel file
remDr$findElement(using = "xpath",'//*[@id="ReportViewer1_ctl05_ctl04_ctl00_Menu"]/div[1]') -> exceldownload
exceldownload$clickElement()
Related Topics
Automated Formula Construction
How Is J() Function Implemented in Data.Table
Additional Metrics in Caret - Ppv, Sensitivity, Specificity
How to Print a Variable Inside a for Loop to the Console in Real Time as the Loop Is Running
What Are the Ways to Create an Executable from R Program
Create a New Variable Based on the First 7 Characters of Existing Variable
R Specify Function Environment
Adding Counts of a Factor to a Dataframe
Testing a Function That Uses Enquo() for a Null Parameter
How to Split Data Frame by Column Names in R
Find Matches of a Vector of Strings in Another Vector of Strings
How to Add Legend to Geom_Smooth in Ggplot in R
Enclosing Variables Within for Loop
Sum Specific Columns Among Rows
Print a List of Dynamically-Sized Plots in Knitr
How to Place Legends at Different Sides of Plot (Bottom and Right Side) with Ggplot2