Open PDF in Azure

JORGE MALDONADO BARRERA 186 Reputation points

I have a website in an Azure App Service that generated a pdf. The pdf generates correctly inside a project folder but I also want to open it. I tried the Process.Start("explorer.exe", fileName) which only works when running my project locally and also Process.Start(fileName) which does not open anything. I also tried the following solution without success:

I will appreciate any feedback.


A set of technologies in the .NET Framework for building web applications and XML web services.
3,137 questions
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
4,927 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Ryan Hill 18,406 Reputation points Microsoft Employee


    You won't have access to processes like explorer inside an app service; see Operating system functionality on Azure App Service and Azure Web App sandbox for more details. Furthermore, from a web perspective, the client has to request to open/download the PDF file you've generated. On your local environment, you're the client which is why it works. To do similarly, when client makes the request to your app which generates your PDF, your app will need to respond with application/pdf HTTP response.

    1 person found this answer helpful.
    0 comments No comments