Upload Error

2 posts, 0 answers
  1. Support
    Support avatar
    13 posts
    Member since:
    Feb 2012

    Posted 17 Nov 2014 Link to this post

    Hi, we have a grid with a RadAsyncUpload in EditFormSettings. Is from approximately 2 weeks that RadAsyncUpload don't work fine.

    <telerik:RadGrid ID="RadGrid1" runat="server"
        CellSpacing="0" Culture="it-IT" GridLines="None" DataKeyNames="ID Modulo"
        DataSourceID="SqlDataSource1" AutoGenerateColumns="false" Width="820px" AllowSorting="true"
        OnInsertCommand="RadGrid1_InsertCommand" OnItemCommand="RadGrid1_ItemCommand" OnUpdateCommand="RadGrid1_UpdateCommand"
        Skin="Forest" EnableEmbeddedSkins="False" OnItemDataBound="RadGrid1_ItemDataBound">
        <MasterTableView DataKeyNames="ID Modulo" DataSourceID="SqlDataSource1" CommandItemDisplay="TopAndBottom">
            <ItemTemplate>
                <table style="width:800px;">
                    <tr>
                        <td style="width: 80px;text-align:left;"><telerik:RadBinaryImage ID="RadBinaryImage1" runat="server" Width="64px" Height="64px" ResizeMode="Fit" DataValue='<%# Eval("Immagine") %>' /></td>
                        <td style="width: 100px;">
                            <div class="fModuli"><%#Eval("tProgressivo")%></div>
                            <div class="fModuli"><%#Eval("tTipo")%></div>
                        </td>
                        <td style="width: 400px;">
                            <b>Descrizione:</b> <%#Eval("tModulo")%><br />
                            <b>Data:</b> <%#Eval("tStamp")%>                                   
                        </td>
                        <td>
                            <table style="width:100%">
                                <tr>
                                    <td style="text-align:left;"><asp:LinkButton ID="lnkEdit" runat="server" Text="Modifica" CommandName="Edit"></asp:LinkButton></td>
                                </tr>
                                <tr>
                                    <td style="text-align:left;"><asp:LinkButton ID="lnkDelete" runat="server" Text="Elimina" CommandName="Delete" OnClientClick="return confirm('Sei sicuro di volerlo eliminare?')"></asp:LinkButton><asp:LinkButton ID="lnlDomRisp" runat="server" Text="Domande" CommandName="DomRis"></asp:LinkButton></td>
                                </tr>
                            </table>                               
                        </td>
                    </tr>
                </table>
            </ItemTemplate>
            <Columns>
                <telerik:GridTemplateColumn>
                    <HeaderStyle Width="130px" />
                </telerik:GridTemplateColumn>
                <telerik:GridBoundColumn HeaderText="Progressivo" DataField="Progressivo" UniqueName="Progressivo">
                    <HeaderStyle Width="490px" />
                </telerik:GridBoundColumn>
                <telerik:GridTemplateColumn>
                    <HeaderStyle Width="200px" />
                </telerik:GridTemplateColumn>
            </Columns>
            <EditFormSettings EditFormType="Template">
                <FormTemplate>
                    <div style="margin-left:15px;">
                        <asp:Panel ID="pnlInsert" runat="server">
                            <div style="height:10px"></div>
                            <table style="width:800px">
                                <tr>
                                    <td style="width:200px">Tipo Modulo <asp:DropDownList ID="DDLTipoModulo" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DDLTipoModulo_SelectedIndexChanged" DataTextField="Descrizione" DataValueField="ID Tipo Modulo"></asp:DropDownList></td>
                                </tr>
                            </table>
                        </asp:Panel>   
                        <div style="height:10px"></div>
                        <table style="width:800px;">
                            <tr>
                                <td style="width:400px; vertical-align:top;">Descrizione:<br /><asp:TextBox ID="txtDescrizione" runat="server" Text='<%#Bind("tModulo")%>' MaxLength="255" Width="350px"></asp:TextBox></td>
                                <td style="vertical-align:top;"><asp:Panel ID="pnlArticulate" runat="server">Articulate: <a href="../public/moduli/<%=Hash%>/<%#Eval("Articulate")%>" target="_blank"><asp:Literal ID="lArticulate" runat="server" Text='<%#Eval("Articulate")%>'></asp:Literal></a><telerik:RadAsyncUpload ID="rupArticulate" runat="server" AllowedFileExtensions="zip" MaxFileSize="1010485760" MaxFileInputsCount="1" Skin="Forest" EnableEmbeddedSkins="False" Localization-Select="Seleziona" Localization-Cancel="Cancella" Localization-Remove="Rimuovi"></telerik:RadAsyncUpload></asp:Panel><asp:Panel ID="pnlDispensa" runat="server">Dispensa: <a href="../public/moduli/<%=Hash%>/<%#Eval("Dispensa")%>" target="_blank"><asp:Literal ID="lDispensa" runat="server" Text='<%#Eval("Dispensa")%>'></asp:Literal></a><telerik:RadAsyncUpload ID="rupDispensa" runat="server" AllowedFileExtensions="pdf" MaxFileSize="1010485760" MaxFileInputsCount="1" Skin="Forest" EnableEmbeddedSkins="False" Localization-Select="Seleziona" Localization-Cancel="Cancella" Localization-Remove="Rimuovi"></telerik:RadAsyncUpload></asp:Panel></td>
                            </tr>
                        </table>
                        <div style="height:10px"></div>
                        <table style="width:800px;">
                            <tr>
                                <td style="width:150px; vertical-align:top"><asp:Panel ID="pnlProgressivo" runat="server">Progressivo: <asp:TextBox ID="txtProgressivo" runat="server" Text='<%#Bind("Progressivo")%>' MaxLength="3" Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="RFVProgressivo" runat="server" ErrorMessage="Inserire il progressivo" ControlToValidate="txtProgressivo" Text="*"></asp:RequiredFieldValidator><asp:RangeValidator ID="RVProgressivo" runat="server" ErrorMessage="Inserire un numero compreso tra 1 e 100" MaximumValue="100" MinimumValue="1" ControlToValidate="txtProgressivo" Text="*" Type="Integer"></asp:RangeValidator></asp:Panel><asp:Panel ID="pnlPercentualeCorrette" runat="server">% Corrette: <asp:TextBox ID="txtPerCorrette" runat="server" Text='<%#Bind("Percentuale_Corrette")%>' MaxLength="3" Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="TFVPerCorrette" runat="server" ErrorMessage="Inserire la percentuale di domande corrette" ControlToValidate="txtPerCorrette" Text="*"></asp:RequiredFieldValidator><asp:RangeValidator ID="RVPerCorrette" runat="server" ErrorMessage="Inserire un numero compreso tra 1 e 100" MaximumValue="100" MinimumValue="1" ControlToValidate="txtPerCorrette" Text="*" Type="Integer"></asp:RangeValidator></asp:Panel></td>
                                <td style="width:150px; vertical-align:top"><asp:Panel ID="pnlDurata" runat="server">Durata: <asp:TextBox ID="txtDurata" runat="server" Text='<%#Bind("Durata")%>' MaxLength="10"  Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="RFVDurata" runat="server" ErrorMessage="Inserire la durata" ControlToValidate="txtDurata" Text="*"></asp:RequiredFieldValidator><asp:RegularExpressionValidator ID="REVDurata" runat="server" Text="*" ErrorMessage="Durata non corretta" ControlToValidate="txtDurata" ValidationExpression="\d+"></asp:RegularExpressionValidator></asp:Panel></td>
                                <td style="vertical-align:top;"><asp:Panel ID="pnlnDomande" runat="server">Numero Domande: <asp:TextBox ID="txtNDomande" runat="server" Text='<%#Bind("Domande_Random")%>' MaxLength="3" Width="50"></asp:TextBox><asp:RequiredFieldValidator ID="RFVNDomande" runat="server" ErrorMessage="Inserire il numero di domande" ControlToValidate="txtNDomande" Text="*"></asp:RequiredFieldValidator><asp:RangeValidator ID="REVNDomande" runat="server" ErrorMessage="Inserire un numero compreso tra 1 e 100" MaximumValue="100" MinimumValue="1" ControlToValidate="txtNDomande" Text="*" Type="Integer"></asp:RangeValidator></asp:Panel></td>
                            </tr>
                        </table>
                    </div>
                    <div style="height:10px"></div>
                    <div style="text-align:center;">
                        <asp:Button ID="btnUpdate" Text='<%# (Container is GridEditFormInsertItem) ? "Inserisci" : "Aggiorna" %>' runat="server" CommandName='<%# (Container is GridEditFormInsertItem) ? "PerformInsert" : "Update" %>' ></asp:Button> <asp:Button ID="btnCancel" Text="Annulla" runat="server" CausesValidation="False" CommandName="Cancel" ></asp:Button>
                    </div>
                    <div style="height:10px"></div>
                    <asp:ValidationSummary ID="VS1" runat="server" ShowMessageBox="true" ShowSummary="false" />
                </FormTemplate>
            </EditFormSettings>
        </MasterTableView>
    </telerik:RadGrid>


    An error was raised

    ReferenceError: xhtml is not defined
    debugger eval code
    Line 1

    in attached the error debug.

    How is possible solve the problem.
  2. Peter Filipov
    Admin
    Peter Filipov avatar
    1028 posts

    Posted 20 Nov 2014 Link to this post

    Hello Pyramid,

    We will need a runnable sample project which reproduces the issue. Please isolate the issue and send it back to us. Does the upload control work on a sample standalone page?

    Regards,
    Peter Filipov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top