Hi
Here we have problem with radUpload control. we have used ajax validation(ValidatorCalloutExtender) in our project.
one of the file i have implemented with RadFileUpload and ajax validation control. but ajax validation control is not working.
if i remove that upload control validation is working and while execution also its giving error as "Radupload callback Error"
please give any example with ajax validation with fileupload.
we have mentained like this.
<telerik:RadGrid
ID="RadGrid1"
runat="server"
Skin="MyCustomSkin"
EnableEmbeddedSkins="false"
GridLines="None"
PageSize = "10"
AllowPaging="True"
PagerStyle-Mode="NextPrevAndNumeric"
AllowSorting="True"
ShowStatusBar="true"
AutoGenerateColumns="False"
AllowMultiRowSelection ="true"
ClientSettings-Selecting-AllowRowSelect="true"
onneeddatasource="RadGrid1_NeedDataSource"
oninsertcommand="RadGrid1_InsertCommand"
onupdatecommand="RadGrid1_UpdateCommand"
ondeletecommand="RadGrid1_DeleteCommand"
onitemcommand="RadGrid1_ItemCommand"
onitemdatabound="RadGrid1_ItemDataBound"
>
<PagerStyle Mode="NextPrevAndNumeric"></PagerStyle>
<MasterTableView GridLines="None" Width="100%" CommandItemDisplay="TopAndBottom"
DataKeyNames="EmployeeFileID" InsertItemPageIndexAction="ShowItemOnFirstPage">
<CommandItemTemplate>
<table align="left">
<tr>
<td width="20"></td>
<td>
<asp:LinkButton ID="LinkButton2" runat="server" CommandName="InitInsert" Enabled='<%# !RadGrid1.MasterTableView.IsItemInserted %>'>
<img style="border:0px;vertical-align:middle;" alt="" src="../images/add.jpg" /> Add new
</asp:LinkButton>
</td>
<td width="10"></td>
<td align="center">
<asp:LinkButton ID="LinkButton1" OnClientClick="javascript:return confirm('Delete all selected Grade Rate?')" runat="server" CommandName="DeleteSelected">
<img style="border:0px;vertical-align:middle;" alt="" src="../images/delete.jpg" /> Delete selected
</asp:LinkButton>
</td>
<td width="10"></td>
<td align="right">
<asp:LinkButton ID="LinkButton4" runat="server" CausesValidation="False" CommandName="RebindGrid">
<img style="border:0px;vertical-align:middle;" alt="" src="../images/refresh.jpg" /> Refresh
</asp:LinkButton>
</td>
<td width="10"></td>
</tr>
</table>
</CommandItemTemplate>
<RowIndicatorColumn>
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>
<ExpandCollapseColumn>
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
<Columns>
<telerik:GridClientSelectColumn HeaderStyle-Width="18px"/>
<telerik:GridBoundColumn DataField="Title" HeaderText="Title"/>
<telerik:GridBoundColumn HeaderText="Comments" DataField="File_description" />
<telerik:GridTemplateColumn HeaderText="Files">
<ItemTemplate>
<asp:Label ID="lblfiles" runat="server"></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
</Columns>
<EditFormSettings EditFormType="Template">
<EditColumn InsertImageUrl="Update.gif" UpdateImageUrl="Update.gif" EditImageUrl="Edit.gif" CancelImageUrl="Cancel.gif" UniqueName="EditCommandColumn1"></EditColumn>
<FormTemplate>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td>Title</td>
<td style="height:2px">
<asp:TextBox ID="txtTitle" runat="server"></asp:TextBox>
<asp:RequiredFieldValidator ID="ReqTitle" runat="server" InitialValue="0" ControlToValidate="txtTitle"
SetFocusOnError="true" ErrorMessage="Title is Required" Display="None" ></asp:RequiredFieldValidator>
<cc1:ValidatorCalloutExtender ID="ValidatorGroupID"
runat="server" TargetControlID="ReqTitle">
</cc1:ValidatorCalloutExtender>
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td>Comments</td>
<td style="height:2px">
<asp:TextBox ID="txtComments" TextMode="MultiLine" runat="server"></asp:TextBox>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td valign="top">File Upload (Allows .txt,.doc)<br>Max Limit 1 MB</td>
<td style="height:2px">
<asp:PlaceHolder ID="EditFileUpload" runat="server"></asp:PlaceHolder>
<telerik:RadUpload id="RadFileUpload1" runat="server" e initialfileinputscount="1"
maxfileinputscount="5" controlobjectsvisibility="All" MaxFileSize="1048576" />
<asp:customvalidator
id="RadUploadImagesValidate"
runat="server"
display="dynamic"
ErrorMessage="Please select valid images" />
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td class="lbl">Start Date Active</td>
<td class="txt">
<asp:TextBox ID="txtStartDateActive" runat="server" style="width:75px" ReadOnly="true"></asp:TextBox>
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td class="lbl">End Date Active</td>
<td class="txt">
<asp:TextBox ID="txtEndDateActive" runat="server" style="width:75px" ReadOnly="true"></asp:TextBox>
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td></td>
<td class="txt">
<asp:LinkButton ID="btnInsert" runat="server" CommandName="PerformInsert" Visible='<%# (Container is GridEditFormInsertItem) ? true : false %>'><img src="../images/insert.jpg" border="0" /></asp:LinkButton>
<asp:LinkButton ID="btnCorrection" OnClientClick="javascript:return confirmEdit('Correction')" runat="server" CommandName="Update" Visible='<%# (Container is GridEditFormInsertItem) ? false : true %>'><img src="../images/correction.jpg" border="0" /></asp:LinkButton>
<asp:LinkButton ID="btnUpdate" runat="server" CommandName="Update" Visible='<%# (Container is GridEditFormInsertItem) ? false : true %>'><img src="../images/update.jpg" border="0" /></asp:LinkButton>
<asp:LinkButton ID="btnClose" runat="server" CommandName="Cancel" CausesValidation="False"><img src="../images/cancel.jpg" border="0" /></asp:LinkButton>
</td>
</tr>
<tr>
<td style="height:5px"></td>
</tr>
<tr>
<td></td><td id="errMsg" class="err_msg" runat="server"></td>
</tr>
<tr>
<td style="height:5px"></td>
</tr>
</table>
</FormTemplate>
</EditFormSettings>
</MasterTableView>
<ClientSettings>
<Selecting AllowRowSelect="True"></Selecting>
</ClientSettings>
<FilterMenu Skin="MyCustomSkin" EnableEmbeddedSkins="False" EnableTheming="True">
<CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation>
</FilterMenu>
</telerik:RadGrid>
please give reply ASAP.
thx.
Here we have problem with radUpload control. we have used ajax validation(ValidatorCalloutExtender) in our project.
one of the file i have implemented with RadFileUpload and ajax validation control. but ajax validation control is not working.
if i remove that upload control validation is working and while execution also its giving error as "Radupload callback Error"
please give any example with ajax validation with fileupload.
we have mentained like this.
<telerik:RadGrid
ID="RadGrid1"
runat="server"
Skin="MyCustomSkin"
EnableEmbeddedSkins="false"
GridLines="None"
PageSize = "10"
AllowPaging="True"
PagerStyle-Mode="NextPrevAndNumeric"
AllowSorting="True"
ShowStatusBar="true"
AutoGenerateColumns="False"
AllowMultiRowSelection ="true"
ClientSettings-Selecting-AllowRowSelect="true"
onneeddatasource="RadGrid1_NeedDataSource"
oninsertcommand="RadGrid1_InsertCommand"
onupdatecommand="RadGrid1_UpdateCommand"
ondeletecommand="RadGrid1_DeleteCommand"
onitemcommand="RadGrid1_ItemCommand"
onitemdatabound="RadGrid1_ItemDataBound"
>
<PagerStyle Mode="NextPrevAndNumeric"></PagerStyle>
<MasterTableView GridLines="None" Width="100%" CommandItemDisplay="TopAndBottom"
DataKeyNames="EmployeeFileID" InsertItemPageIndexAction="ShowItemOnFirstPage">
<CommandItemTemplate>
<table align="left">
<tr>
<td width="20"></td>
<td>
<asp:LinkButton ID="LinkButton2" runat="server" CommandName="InitInsert" Enabled='<%# !RadGrid1.MasterTableView.IsItemInserted %>'>
<img style="border:0px;vertical-align:middle;" alt="" src="../images/add.jpg" /> Add new
</asp:LinkButton>
</td>
<td width="10"></td>
<td align="center">
<asp:LinkButton ID="LinkButton1" OnClientClick="javascript:return confirm('Delete all selected Grade Rate?')" runat="server" CommandName="DeleteSelected">
<img style="border:0px;vertical-align:middle;" alt="" src="../images/delete.jpg" /> Delete selected
</asp:LinkButton>
</td>
<td width="10"></td>
<td align="right">
<asp:LinkButton ID="LinkButton4" runat="server" CausesValidation="False" CommandName="RebindGrid">
<img style="border:0px;vertical-align:middle;" alt="" src="../images/refresh.jpg" /> Refresh
</asp:LinkButton>
</td>
<td width="10"></td>
</tr>
</table>
</CommandItemTemplate>
<RowIndicatorColumn>
<HeaderStyle Width="20px"></HeaderStyle>
</RowIndicatorColumn>
<ExpandCollapseColumn>
<HeaderStyle Width="20px"></HeaderStyle>
</ExpandCollapseColumn>
<Columns>
<telerik:GridClientSelectColumn HeaderStyle-Width="18px"/>
<telerik:GridBoundColumn DataField="Title" HeaderText="Title"/>
<telerik:GridBoundColumn HeaderText="Comments" DataField="File_description" />
<telerik:GridTemplateColumn HeaderText="Files">
<ItemTemplate>
<asp:Label ID="lblfiles" runat="server"></asp:Label>
</ItemTemplate>
</telerik:GridTemplateColumn>
</Columns>
<EditFormSettings EditFormType="Template">
<EditColumn InsertImageUrl="Update.gif" UpdateImageUrl="Update.gif" EditImageUrl="Edit.gif" CancelImageUrl="Cancel.gif" UniqueName="EditCommandColumn1"></EditColumn>
<FormTemplate>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td>Title</td>
<td style="height:2px">
<asp:TextBox ID="txtTitle" runat="server"></asp:TextBox>
<asp:RequiredFieldValidator ID="ReqTitle" runat="server" InitialValue="0" ControlToValidate="txtTitle"
SetFocusOnError="true" ErrorMessage="Title is Required" Display="None" ></asp:RequiredFieldValidator>
<cc1:ValidatorCalloutExtender ID="ValidatorGroupID"
runat="server" TargetControlID="ReqTitle">
</cc1:ValidatorCalloutExtender>
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td>Comments</td>
<td style="height:2px">
<asp:TextBox ID="txtComments" TextMode="MultiLine" runat="server"></asp:TextBox>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td valign="top">File Upload (Allows .txt,.doc)<br>Max Limit 1 MB</td>
<td style="height:2px">
<asp:PlaceHolder ID="EditFileUpload" runat="server"></asp:PlaceHolder>
<telerik:RadUpload id="RadFileUpload1" runat="server" e initialfileinputscount="1"
maxfileinputscount="5" controlobjectsvisibility="All" MaxFileSize="1048576" />
<asp:customvalidator
id="RadUploadImagesValidate"
runat="server"
display="dynamic"
ErrorMessage="Please select valid images" />
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td class="lbl">Start Date Active</td>
<td class="txt">
<asp:TextBox ID="txtStartDateActive" runat="server" style="width:75px" ReadOnly="true"></asp:TextBox>
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td class="lbl">End Date Active</td>
<td class="txt">
<asp:TextBox ID="txtEndDateActive" runat="server" style="width:75px" ReadOnly="true"></asp:TextBox>
</td>
</tr>
<tr>
<td style="height:2px"></td>
</tr>
<tr>
<td></td>
<td class="txt">
<asp:LinkButton ID="btnInsert" runat="server" CommandName="PerformInsert" Visible='<%# (Container is GridEditFormInsertItem) ? true : false %>'><img src="../images/insert.jpg" border="0" /></asp:LinkButton>
<asp:LinkButton ID="btnCorrection" OnClientClick="javascript:return confirmEdit('Correction')" runat="server" CommandName="Update" Visible='<%# (Container is GridEditFormInsertItem) ? false : true %>'><img src="../images/correction.jpg" border="0" /></asp:LinkButton>
<asp:LinkButton ID="btnUpdate" runat="server" CommandName="Update" Visible='<%# (Container is GridEditFormInsertItem) ? false : true %>'><img src="../images/update.jpg" border="0" /></asp:LinkButton>
<asp:LinkButton ID="btnClose" runat="server" CommandName="Cancel" CausesValidation="False"><img src="../images/cancel.jpg" border="0" /></asp:LinkButton>
</td>
</tr>
<tr>
<td style="height:5px"></td>
</tr>
<tr>
<td></td><td id="errMsg" class="err_msg" runat="server"></td>
</tr>
<tr>
<td style="height:5px"></td>
</tr>
</table>
</FormTemplate>
</EditFormSettings>
</MasterTableView>
<ClientSettings>
<Selecting AllowRowSelect="True"></Selecting>
</ClientSettings>
<FilterMenu Skin="MyCustomSkin" EnableEmbeddedSkins="False" EnableTheming="True">
<CollapseAnimation Type="OutQuint" Duration="200"></CollapseAnimation>
</FilterMenu>
</telerik:RadGrid>
please give reply ASAP.
thx.