This is a migrated thread and some comments may be shown as answers.

Fire Select button on page load

1 Answer 27 Views
Upload (Obsolete)
This is a migrated thread and some comments may be shown as answers.
Dave
Top achievements
Rank 1
Dave asked on 15 Oct 2008, 08:25 PM


Can you tell me how to fire the select button on page load?  I would like to have the file browse window appear right away when the page loads without the user having to click the select button.

I have attempted to add to the onclientadded handler with no luck.  I am trying to configure a simple one file upload within a window control.

Seems like a simple task not sure why I am having so much trouble with it.

Thanks,
Dave

1 Answer, 1 is accepted

Sort by
0
Erjan Gavalji
Telerik team
answered on 16 Oct 2008, 07:25 AM
Hi Dave,

Here is a copy of my post to your support ticket:

To my regret, due to browser restrictions, the programmatic call of the browse dialog of a file input would further prevent the selected file from being uploaded. What I mean is that you can call the file input's click() method to open the Browse dialog. However, using this approach, when you submit the form you would either get an "Access is denied" error, or you would end up with the file input cleared and the page not submitted depending on the type f button you click to submit the form.

You can implement some kind of a workaround by allowing your users to submit the form only if they have selected a file.


Kind regards,
Erjan Gavalji
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Upload (Obsolete)
Asked by
Dave
Top achievements
Rank 1
Answers by
Erjan Gavalji
Telerik team
Share this question
or