0

im Using selenium version 2.8.0 and FF 31.0 on Mac OS X and the scripts are in HMTL Format

My work involving checking the process/flow of our website and now i am faced with the problem of automating the uploading of excel file to the website

right now the script command will click on "file upload" button on the website and a window will pop up for me to select my excel file in my finder but i have add a command that pause for say 10seconds to give me time to manually select the file.

curent scripts commands are:

click on the "select file" button on FF

Pause 10seconds while i find and open excel file to be upload

i tried to change to format to java or C# under options > format tab but it doesnt allow me to run the scripts after editing the command in the "source" tab.

Am i missing some plugins to allow me to edit my scripting command in other formats?

Mervin
  • 11
  • 5

2 Answers2

0

File upload is fairly easier than file download. If you write a your selector correctly

 Driver.Sendkeys("filepath") should simply upload the file
Saifur
  • 16,081
  • 6
  • 49
  • 73
0

It sounds like you're using Selenium IDE. You'll need to migrate to Selenium WebDriver if you want more sophisticated language features. See this answer for more.

This question has a working Python snippet that uploads a file, though annoying the file selector dialog box doesn't go away once the file is selected.

Community
  • 1
  • 1
kuzzooroo
  • 6,788
  • 11
  • 46
  • 84