I call the .getAttribute("value")
method on an input
element with type="file"
to get the uploaded filename but it doesn't work. I get an empty string. This works with all other browsers but not Edge. Is this a known Edge bug or am I doing something wrong?
WebElement fileDialog = driver.findElement(By.id("fileDialogID"));
String uploadedFilename = fileDialog.getAttribute("value")