Link to home
Start Free TrialLog in
Avatar of Mark Klein
Mark KleinFlag for United States of America

asked on

One step image load and display

I am building an website in which a user picks an image from the user's file system and displays it on the site.  The code is presently working as a two step process:
1. Use FileUpload control to let the user select a file from local storage.  A Browse button is shown, and the user picks the file with the file name in the control
2. User clicks a Display button.  The file is checked and displayed so the user can add a description before uploading to db.

My client wants a one-step process, eliminating the Display button. I have unsuccessfully tried to implement this by triggering on the FileUpload events.  I've tried them all, w/o success. FileUpload only captures the file name.  How do I kick off my processing routines without another button click?
Avatar of Nasir Razzaq
Nasir Razzaq
Flag of United Kingdom of Great Britain and Northern Ireland image

The form has to be posted back to the server for the file to be uploaded. This postback is usually done by button click.

To do what you want, you would need to use either Flash/silverlight or ActiveX.
Avatar of PaulHews
Flag of Canada image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Mark Klein


Had to adjust the filepath slightly, adding "~/" and then it worked.  Thx