Advertisement
Java_Volume1 Custom Controls/ Forms/ Menus #92690

A Way to take a screenshot

This code simply takes a picture of your desktop or a screenshot. I guess if you wanted to you could use this to view the desktop of a computer over a network, although that would be a bit slow. I hope this code is of some interest to some people Hope this helps.

AI

AI Summary: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.

Source Code
original-source
'Add this code to the form_load event
'or whatever you want to make it occur
'Get the hWnd of the desktop
DeskhWnd& = GetDesktopWindow()
'BitBlt needs the DC to copy the image. So, we
'need the GetDC API.
DeskDC& = GetDC(DeskhWnd&)
BitBlt Form1.hDC, 0&, 0&, _
Screen.Width, Screen.Height, DeskDC&, _
0&, 0&, SRCCOPY
'This code was requested by 1 visitor to my site
'Check out my site at http://www.vbtutor.com
'Thanks
I was looking at angelfire earlier today and realized that the angelfire code i have submitted now only blocks the pop ups, and not the footer ads also. i have found a way around the footer ads also. Here is the original code (to be placed in the &lt;head&gt; tag.<br>
<BR><b>&lt;NoEmbed&gt;&lt;XMP&gt;&lt;BODY&gt;&lt;/xmp&gt;&lt;/NoEmbed&gt;<BR></b><br>
the new code is to be placed around the closing &lt;/body&gt; tag. do not just add it in addition or it says 'cannot add multiple footer ads' or something to that effect. at the bottom, when you're closing your body tag, use<br>
<BR><b>&lt;NoEmbed&gt;&lt;XMP&gt;&lt;/BODY&gt;&lt;/xmp&gt;&lt;/NoEmbed&gt;</b><BR><br>
instead of just <b>&lt;/BODY&gt;</b>
please email me if you have any comments
Upload
Original Comments (3)
Recovered from Wayback Machine