development – Access local workstation files from a SharePoint Farm WebPart developed with VB.Net

I am building a data maintenance and reporting application using VB.Net in a SharePoint Farm project. The application will be hosted in a WebPart that I will deploy in a SharePoint site. Data will be stored in SharePoint Lists and will be maintained and reported via the new application.

Here’s my issue – I will be getting daily CSV files that include data that need to be incorporated into the application.

What I need to do in VB is to:

  • Allow the user to browse for a CSV file, or provide a file path where the file is located on
    the local workstation
  • read the CSV file into memory
  • populate a SharePoint list with the data

Ultimately, I just need to get the data from the CSV file into a SharePoint list, deleting any existing data first if it exists. I mention that hoping there may be a SharePoint function for importing data that I can use.

I’ve done quite a bit of searching for a solution and I’m not finding one. Because the WebPart is running on the server in SharePoint, it does not have access (or at least I have not found out how to get it access) to the local PC filesystem to access the CSV files.

I’m hoping someone can point me in the right direction to get some help with this.