0

I currently have a way for a user to upload a csv to my website and I'm looking to see if there is a way to create a new view/page for each row on the csv. Right now the csv can have any number of rows so I wanted to see if this is the best option or to limit the number of rows the user can upload and create that many views manually.

I have looked into partial views but don't think that will work. I've also looked into limiting the number of rows on the csv so I won't have to use the for loop to create the views.

Have a separate view/page for each row, but right now I only have one view pulling the first row.

Heretic Monkey
  • 11,687
  • 7
  • 53
  • 122
  • 3
    Sounds like an [XY Problem](https://xyproblem.info). Do you need to show something different in each of these views? Otherwise, just use different instances of the same partial view. – Heretic Monkey May 20 '19 at 14:05
  • Yeah I'm looking to show something different for each view based on the info in the row from the csv. For example a new page will be create for each team with their location, national rank, coach, etc. – Nicktrotter4 May 20 '19 at 14:23
  • https://stackoverflow.com/questions/37854497/create-view-from-a-controller-in-asp-net-mvc looks like it will work for what I'm looking to do. – Nicktrotter4 May 20 '19 at 14:37

0 Answers0