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

Pre select image file from database

2 Answers 64 Views
AsyncUpload
This is a migrated thread and some comments may be shown as answers.
Andy Green
Top achievements
Rank 2
Andy Green asked on 26 Jul 2012, 01:20 PM
When you select an image for upload the control changes its view to show a remove link and the image file.

Is it posible to preload this image from tha value shown in the database.

The idea would be that this image is persisted in the update statement for the record. If you no long want the image it can be removed and either e new one is selected or an "" is sent back to the database.
Andy

2 Answers, 1 is accepted

Sort by
0
Genady Sergeev
Telerik team
answered on 30 Jul 2012, 04:17 PM
Hello Andy,

Unfortunately it is not possible to prepopulate the async upload with files. RadAsyncUpload can only manipulate files uploaded during the current session, whereas you are looking for something like file explorer. I suggest that you take a look at the file explorer demos, perhaps you can achieve what you want using a custom provider for it.


Kind regards,
Genady Sergeev
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Andy Green
Top achievements
Rank 2
answered on 30 Jul 2012, 04:32 PM
Thanks Genady

I came to the same conclusion.

Attached file is my solution - a bit of a cheat, I used a placeholder with an image and a button to replicate the look and feel of your control, and simply swap it out when there is data in the field.

Andy
Tags
AsyncUpload
Asked by
Andy Green
Top achievements
Rank 2
Answers by
Genady Sergeev
Telerik team
Andy Green
Top achievements
Rank 2
Share this question
or