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.
61e492544b8754c3c21b48f2aefb0987?d=identicon&s=25 Bibhu Behera (bibhu_behera)
on 2009-03-13 11: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 ?
4a825f70d8c13052c50f31457d7456a3?d=identicon&s=25 Bassel Samman (mercedes6s)
on 2009-03-13 14: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.