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

How To Upload Async upload Dynmically, when user Click's On Rad Grid Edit.

1 Answer 99 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Sairam
Top achievements
Rank 1
Sairam asked on 24 May 2013, 12:35 PM
I Have rad grid ,In that I have Rad Async upload ,when   user click On edit button of rad grid , i want to dynamically upload the file like ,when user select the click on async upload control ,that mean in rad grid ,I have some records,when user click on ,one record Edit Button
at that time I want ,to Upload same picture to rad Async Upload ,Is any chance to that .

I have idea,when user click on that edit button ,at the time ,we save already display  item in ,rad grid ,It stores ,In Some Download or Some temp folder,at same time ,we call async  upload file functionality Dynamically.upload file ,,

can u plz help in that situation,where we store the file  ,how to dynamically load the file.sample snippet provided to me .

  1.  
    1.    <telerik:GridTemplateColumn Visible="true" DataField="Signature" HeaderText="Signature"
    2.                     HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" UniqueName="Signature">
    3.                     <ItemTemplate>
    4.                         <telerik:RadBinaryImage ID="RadBinaryImage1" runat="server" DataValue='<%#Eval("Signature") is DBNull ? null : Eval("Signature")%>'
    5.                             AutoAdjustImageControlSize="false" ResizeMode="Fit" Height="50px" Width="120px" />
    6.                     </ItemTemplate>
    7.                     <InsertItemTemplate>
    8.                         <telerik:RadAsyncUpload runat="server" ID="ImgImages2" AllowedFileExtensions=".jpg,.jpeg,.png,.gif"
    9.                             MaxFileInputsCount="1" Skin="Outlook" Width="350px" PostbackTriggers="PerformInsertButton" />
    10.                         <asp:Label ID="lblupload2" runat="server" Visible="true" CssClass="error"></asp:Label>
    11.                        
    12.                     <EditItemTemplate>
    13.                       
    14.                         <telerik:RadAsyncUpload runat="server" ID="ImgImages" AllowedFileExtensions=".jpg,.jpeg,.png,.gif"
    15.                             MaxFileInputsCount="1" Skin="Outlook" Width="350px" PostbackTriggers="UpdateButton" />
    16.                       
    17.                         <asp:Label ID="lblupload1" runat="server" Visible="true" CssClass="error"></asp:Label>--%>
    18.                     </EditItemTemplate>
    19.                 </telerik:GridTemplateColumn>



             



1 Answer, 1 is accepted

Sort by
0
Accepted
Hristo Valyavicharski
Telerik team
answered on 29 May 2013, 12:00 PM
Hi Sairam,

This scenario is not supported. For security reasons it is not allowed to dynamically load file in RadAsyncUpload control. I suggest to change your logic. For example you could add/copy the same file for every record of the grid, without interaction with the upload control.

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 their blog feed now.
Tags
General Discussions
Asked by
Sairam
Top achievements
Rank 1
Answers by
Hristo Valyavicharski
Telerik team
Share this question
or