Forum: Ruby want to upload file using Browse button.

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Bibhu B. (Guest)
on 2009-03-13 12:23
Below is the code:

$ie.file_field(:id,'_20_file').click_no_wait

$ie.file(:id,'_20_file').click

$ie.button(:id,'_20_file').click


Not working above all script. Please any pointer ?
Bassel S. (Guest)
on 2009-03-13 15:12
I assume you're talking about watir. I don't think you need to click,
but maybe focus.  you can don't need to click.  You can do
$ie.file_field(:id,'_20_file').set('C:\<Path_to_file>')

thanks,

Bassel
http://www.imustrant.com


Bibhu Behera wrote:
> Below is the code:
>
> $ie.file_field(:id,'_20_file').click_no_wait
>
> $ie.file(:id,'_20_file').click
>
> $ie.button(:id,'_20_file').click
>
>
> Not working above all script. Please any pointer ?
This topic is locked and can not be replied to.