Click here to Skip to main content
15,890,579 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
I implemeted the multiple file upload using jquery from this site.. It works correctly when individually implement in Default.aspx without the server form tag.. but when implemented inside multiview control its getting error "Error: SyntaxError: JSON.parse: unexpected character".. I tried all possible ways but I could not achieve the proper result.
ASP.NET
<form id="form1"  runat="server"> 
       <asp:Menu
           ID="menuTabs"
           CssClass="menuTabs"
           StaticMenuItemStyle-CssClass="tab"
           StaticSelectedStyle-CssClass="selectedTab"
           Orientation="Horizontal"
           runat="server" OnMenuItemClick="menuTabs_MenuItemClick">
           
           <Items>
              <asp:MenuItem Text="Home" Value="0" Selected="true"></asp:MenuItem>
              <asp:MenuItem Text="My Uploads" Value="1"></asp:MenuItem>
           </Items>
      </asp:Menu>
      
      <asp:MultiView ID="multiTabs" ActiveViewIndex="0" runat="server">
              <asp:View ID="view1" runat="server">
                 <form id="fileUploaderForm" method="post" action="FileTransferHandler.ashx">
                   <div class="fileupload-buttonbar">
                       <label class="fileinput-button"><span>Add files...</span>
                            <input type="file" name="files[]" multiple="multiple" />
                       </label>
                    </div>
                 </form>
              </asp:View> 
              <asp:View ID="view2" runat="server"> 
                      <!-- Grid view of uploaded files (implemented successfully)-->
              </asp:View>
      </asp:MultiView>
</form> 

Please suggest other possible solutions to get the output like this..in core asp-c# without flash. Else please help to fix this bug..
Posted
Updated 17-Apr-13 0:29am
v4
Comments
sri senthil kumar 18-Apr-13 1:40am    
I think we cannot have nested form but am not sure. If you move the html form out of asp form, i hope it will work...
Janani Muthaiyan 18-Apr-13 2:08am    
Yes.. It will I know.. But I need this form inside mutiview control.. so what to do

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900