The RadAsyncUpload control is used on forms with other controls, and sometimes we need to validate the control, that is require that the user uploads a file before the form can be submitted. We have to use a Customvalidator and check the controls client-side properties to see if it has a file. But if you set the ControltoValidate property an exception occurs. Please support this property so that a radAsyncUpload control can be associated with an ASP.Net validator.
Workaround - Toggle drop zone visibility or enable/disable it, using AsyncUpload OnClientFileUploaded and OnClientFileUploadRemoved events: <div class="dropfile" style="height: 20px; width: 120px; background-color: red; display: block"> </div> <telerik:RadAsyncUpload ID="fimFileImport" runat="server" DropZones=".dropfile" MaxFileInputsCount="1" RenderMode="Lightweight" OnClientFileUploaded="OnClientFileUploaded" OnClientFileUploadRemoved="OnClientFileUploadRemoved" > </telerik:RadAsyncUpload> <script type="text/javascript"> function OnClientFileUploaded(sender, args) { var maxFileCount = sender.get_maxFileCount(); var uploadedFilesLength = sender.getUploadedFiles().length; if (maxFileCount === uploadedFilesLength) { $telerik.$('.dropfile').hide(); } } function OnClientFileUploadRemoved(sender, args) { var maxFileCount = sender.get_maxFileCount(); var uploadedFilesLength = sender.getUploadedFiles().length; if (maxFileCount > uploadedFilesLength) { $telerik.$('.dropfile').show(); } } </script>
File drag and drop is broken in MS Edge Creator's Edition. Reproducible in the following demo: http://demos.telerik.com/aspnet-ajax/asyncupload/examples/draganddrop/defaultcs.aspx
Why not add a "basic mode" to radasyncupload? that saves the selected file(s) in the target folder as soon as the upload is complete without the need for an extra postback? Or facilitate a postback through a popup "upload complete" with an ok button? And a little feedback in general on the documentation nearly all the examples have all the bells and whistles active, which makes them hard to read for programmers with little experience like me. Why not have every control with a absolutely minimalistic example that only shows the core functionality?
The drop zone and the custom drop zones are shifted below their expected positions in Edge 40. Check the following video demonstration https://www.screencast.com/t/2m8SxR8jbwb. The problem is reproducible in the http://demos.telerik.com/aspnet-ajax/asyncupload/examples/draganddrop/defaultcs.aspx demo.
<telerik:RadAsyncUpload ID="UploadFile" runat="server" MultipleFileSelection="Automatic"
OverwriteExistingFiles="true" ReadOnlyFileInputs="true" InputSize="45" EnableViewState="true" TargetFolder="~/UploadedFiles">
</telerik:RadAsyncUpload>
Steps to reproduce:
Hello,
I have a problem with postback on RadAsyncUpload in my project.
So, I created a simple project, with your example (https://docs.telerik.com/devtools/aspnet-ajax/controls/asyncupload/how-to/how-to-persist-uploaded-files) and the problem remains.
if I define PostbackTriggers on the aspx page, after the post back, I can see the files uploaded on the page, but the UploadedFiles.Count in code behind returns zero.
<telerik:RadAsyncUpload runat="server" ID="RadAsyncUpload1" PostbackTriggers="Button3,Button4"></telerik:RadAsyncUpload>
if I define PostbackTriggers on the aspx.vb page, after the post back I can't see the files uploaded on the page, but the UploadedFiles.Count in code behind returns 1.
RadAsyncUpload1.PostbackTriggers = New String() {Button1.ClientID, Button2.ClientID}
So, there is no way to, after the postback, present the uploaded files in page and values in RadAsyncUpload.UploadedFiles.
Please, check the attach files.
Best Regards,
Mauro Santos