Using this code will I be able to access on client machine the folder AppData

Viewed 42

If I publish an Asp.Net core application to IIS. And in my controller I have the following action method. Will I be able to access the clients AppData folder.

Public async Task<IActionResult>  Downloadd()
  {
    
  Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)

    Return View ();
  }
1 Answers

No, it'll be path of machine which is hosting your application.

Depends from your task, if you need to get some files from client (by constant path), one of the possible ways is to configure FTP Server on your server and FTP Client on your client. Then you can create FTP User on server and when necessary, send files from client to server with credentials of FTP User.

Related