locked
How to dynamically attach multiple file for a particular Item RRS feed

  • Question

  • User2059416818 posted

    Hi ,

    I want to attach the line item for each product one by one with delete option.

    Here I am uploading bulk of files working well. But I want to upload one file at a time. If I upload next file it should not overwrite the existing file instead it should append below one by one and it should be removable

    Please view the below attachment

    Tuesday, December 5, 2017 3:27 AM

Answers

  • User-1838255255 posted

    Hi poornima82,

    According to your description, I hope you could check the tutorial in my previous post. You could upload file one by one in that sample, then could delete it one by one. 

    You could replace delete button with image. 

    Here is the result of that sample: 

    Please check this sample(https://www.aspsnippets.com/Articles/Upload-files-save-in-folder-and-display-in-ASPNet-GridView-with-Download-and-Delete-option.aspx) again.

    Best Regards,

    Eric Du 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, December 12, 2017 8:33 AM

All replies

  • User-1838255255 posted

    Hi poornima82,

    According to your description, i think you could save the uploaded file in the folder then show it in the page, then continue to upload the next file. Here is a sample about how to achieve this, please check:

    Upload files, save in folder and display in ASP.Net GridView with Download and Delete option:  

    https://www.aspsnippets.com/Articles/Upload-files-save-in-folder-and-display-in-ASPNet-GridView-with-Download-and-Delete-option.aspx 

    Also you could store uploaded files name in session and save files in server, show them in page load event, then add the delete function after these names. 

    Best Regards,

    Eric Du 

    Tuesday, December 5, 2017 7:52 AM
  • User2059416818 posted

    Hi Eric,

    Thanks for your reply.

    The existing programming i am storing all files in a folder  in root path then storing it in a Database for each product.

    I am attaching 2 items for a Product(879).Item 879_1 has 3 attachments and Item 879_2 has 6 items.

    Please see the below image,

    But here my problem is, at a time i can able to select multiple files and storing in a folder. Now the requirement is , to attach files one by one with delete option and display images or files one below another. In my existing one, if I select one image it overwrites the existing image. 

    Regards,

    Poornima

    Tuesday, December 5, 2017 8:19 AM
  • User-1838255255 posted

    Hi poornima82,

    According to your description, I hope you could check the tutorial in my previous post. You could upload file one by one in that sample, then could delete it one by one. 

    You could replace delete button with image. 

    Here is the result of that sample: 

    Please check this sample(https://www.aspsnippets.com/Articles/Upload-files-save-in-folder-and-display-in-ASPNet-GridView-with-Download-and-Delete-option.aspx) again.

    Best Regards,

    Eric Du 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, December 12, 2017 8:33 AM