Monday, July 27, 2009

How to handle clipboard and how to take screen shot using C language?

Some times we have to handle clipboards, to get the file stored in it and is it any way to take the screen shot of the screen using C language.

How to handle clipboard and how to take screen shot using C language?
Yes, you need to get documentation for the API of the operating system you are writing for. I'm guessing you are writing for Windows, so I'd root around on the Microsoft site, or better yet go to amazon and search for "windows programming". I just tried it, and got some hits.
Reply:I don't know of any ready-made function to take a screen shot with C.





I know that in Windows you can take a screen shot by pressing "Print Screen". Windows will place that into the clipboard. Since you are already using the clipboard you might could copy that (I think it makes a BMP, not sure) image out of the clipboard and use it somehow. I've seen some things about working with that function, invoking it on it's own without pressing print screen and things like that but I can not remember exactly. You might want to google that.





If you're not using windows maybe you should have been more specific?


No comments:

Post a Comment