3

I have a web application running under a .NET v4.0 integrated pipeline 64-bit application pool in IIS 8. My web application needs to take a screenshot (using Selenium / Chromedrive).

The problem I'm running into is that the image is generated by another application (dynamically), called by my web application and started as a child process under the IIS worker process.

As it happens, this application needs to create a window (i.e., GUI window) as large as the image before it can take a snap shot of it and send the image data back to the web application. This GUI window is created on the server machine, although invisible.

Now, normally this application works fine running by itself, as I have a large wide-screen monitor with 1920x1200 limit. So the OS maximum window size limit does not factor in. However, when the application is running under the IIS 8 worker process, it seems the worker process places an arbitrary 1024x768 resolution limit on any applications running within it (despite the fact that I have my large monitor attached to the same machine).

So now the application can only create a window of 1024x768 size, and then the resulting snapshot comes out with this size. And i need to take a screenshot in 1920x1200

I suppose that due to the IIS worker process isolation going on, any applications under it cannot see the full resolution capabilities of the server and only works with what IIS gives it.

Is there any way I can remove this restriction so that applications running under the IIS worker process can create windows larger than 1024x768?

Thanks!

CSharpShooter
  • 138
  • 1
  • 6
  • Because it runs in session 0 and does not really have a "screen". There would be no way to go. If you do want to run a web server in user session, switch to IIS Express. – Lex Li Jul 05 '16 at 00:13

1 Answers1

2

After long research there is NO WAY to do that... i ended by using a docker container with SELENIUM to do the screenshots in resolution greater than 1024x768

Bonus, it's a lot more stable than doing it through a sub process started by IIS

https://hub.docker.com/r/selenium/node-chrome/

CSharpShooter
  • 138
  • 1
  • 6