Hi,
I want to set upload file image of RadAsyncUpload (Please see screenshot)
from code behind?
How can we achieve this?
I want to set upload file image of RadAsyncUpload (Please see screenshot)
from code behind?
How can we achieve this?
3 Answers, 1 is accepted
0
Hi Vinayak,
Please clarify what exactly are you trying to achieve:
* Do you want to place border around the uploaded file?
* Do you want to generate a thumb of the uploaded file (if applicable)?
* Do you need to put an icon in front of the file based on the file type?
* Do you want to pre-set the name of the file to be uploaded from code behind?
All but the last are possible due to browser security restrictions.
Regards,
Hristo Valyavicharski
Telerik
Please clarify what exactly are you trying to achieve:
* Do you want to place border around the uploaded file?
* Do you want to generate a thumb of the uploaded file (if applicable)?
* Do you need to put an icon in front of the file based on the file type?
* Do you want to pre-set the name of the file to be uploaded from code behind?
All but the last are possible due to browser security restrictions.
Regards,
Hristo Valyavicharski
Telerik
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 the blog feed now.
0
Vinayak
Top achievements
Rank 1
answered on 17 Sep 2013, 10:23 AM
I want icon beside uploaded filename (a green one), And remove image to be set from code behind.
0
Hi,
The default green and red icons are loaded from the assembly as an embedded resource and are applied as background image to the selected files. It is possible to change this background image, so you can include your icons. However there is no easy way to apply the new image from code-behind. You should use CSS:
Sample project is attached.
Regards,
Hristo Valyavicharski
Telerik
The default green and red icons are loaded from the assembly as an embedded resource and are applied as background image to the selected files. It is possible to change this background image, so you can include your icons. However there is no easy way to apply the new image from code-behind. You should use CSS:
<style type=
"text/css"
>
html .RadUpload .ruUploadSuccess, .RadUpload .ruUploadFailure, .RadUpload .ruUploadCancelled {
background-image
:
url
(
"img/back.jpg"
);
}
</style>
Regards,
Hristo Valyavicharski
Telerik
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 the blog feed now.