Windows service does not support Capturing Screen with GDI in vb.net

H

hemant

I am trying to Caputre the screen in windows service with the GDI Api
of Win32 in vb.net
1. CreateDc
2. CreateCompatibleDC
3. CreateCompatibleBitmapDc
4. Bitblt
5. SelectObject
6. DeleteDc

The Caputured screen file is always black

Give me the coorrect solution to caputure the scrren in windows service
with vb.net 2005
 
S

Steve C. Orr [MCSD, MVP, CSM, ASP Insider]

Considering this forum is on ASP.NET, it's probably not the best place to
ask a question like this.
However, I would also like to know the solution if you come across it.
The problem is that a windows service is not associated with any user's
desktop, so it does not know which desktop to grab a screen capture from.
Multiple users could be logged in at once through the "switch user" feature
of windows.
I tried to do something similar, and the best I could come up with is to run
a background app when the user logs in (instead of a windows service) so it
has access to their desktop.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,754
Messages
2,569,527
Members
44,997
Latest member
mileyka

Latest Threads

Top