Solved

ALT+PRINT SCREEN

Posted on 1997-03-11
1
255 Views
Last Modified: 2013-11-19
I would like to know how to simulate the keystroke ALT+PRINT SCREEN.   I need to get a snap snot of the screen and put to the clipboard with out hitting the keystroke ALT+PRINT SCREEN.  How would I do this?
0
Comment
Question by:jgraham031197
1 Comment
 
LVL 11

Accepted Solution

by:
mikeblas earned 100 total points
Comment Utility
You can get a screen DC by calling

      HDC hdcScreen = ::GetDC(NULL);

Given that DC, you can use StretBlt() to copy the bitmap on the screen to your own DC.  Then, you can use GetObject() get the raw bitmap bits and load up your own HBITMAP structure to toss onto the clipboard.

I think a couple of the SDK samples have source code that demonstrates this kind of thing.

.B ekiM


0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
cat dog challenge 18 122
Doc'in system (example?) BA 7 77
scoreUp challenge 14 47
wordcount challenge 11 71
This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes.  I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.   Introductio…
Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now