Creating Windows Bitmaps to Save Desktop Images into BMP and JPG Files

Environment: VC6, Win2000 SP2

This dialog-based VC++ application can be used to save the desktop images into BMP or JPG files. This application can also be used to save this window image into BMP or JPG files. By making minor modifications, we can save any window image into a BMP or JPG file just by obtaining its handle. The library that I have used to process JPEG images is a standard third-party source.

The mainly used functions are SaveWindowAsFile and SaveDesktopAsFile.

Downloads

Download demo project - 232 Kb
Download Library source - 773 Kb


Comments

  • Welcome to work in Microsoft! your article is worth of 1000 longhorn

    Posted by Legacy on 01/20/2004 12:00am

    Originally posted by: Bill Gates

    GREAT!

    Reply
  • Works on WinXP, but not on Win2K

    Posted by Legacy on 12/11/2003 12:00am

    Originally posted by: Andreas Klinkert

    I made the following experience:
    On WinXP:
    *********
    Working for all color depths.

    On Win2K:
    *********
    - True Color (24 Bit):
    Not working (black output).
    - High Color (16 Bit), 256 Colors:
    Not working (wrong colors, offsets, ...)

    Reply
  • Help Me.!! It's not working DesktopToBitmap & WindowToBitmap.!

    Posted by Legacy on 12/07/2003 12:00am

    Originally posted by: Dillip

    Hi!.,
    DesktopToBitmap & WindowToBitmap result give blanks output.with this attached sample project . Can you send me correct one.?

    Thanks & Regards.,
    DILLIP.

    Reply
  • remote desktop capture

    Posted by Legacy on 09/05/2003 12:00am

    Originally posted by: beena

    it is a nice work. will u plz help me in capturing the desktop of a remote client frm server machine

    Reply
  • Remote Desktop Capture?

    Posted by Legacy on 08/26/2003 12:00am

    Originally posted by: Ant Haji

    How can I capture the Desktop of a remote computer? Thanx in advance.

    Antonis.

    Reply
  • Excellent work.

    Posted by Legacy on 07/20/2003 12:00am

    Originally posted by: Derek Evans

    Excellent work.

    Reply
  • Thanks for your GOOD WORK! It's very helpful for me.

    Posted by Legacy on 05/03/2003 12:00am

    Originally posted by: Jasion Wa

    Thanks for your GOOD WORK! It's very helpful for me.

    Reply
  • Nice work Senthil

    Posted by Legacy on 04/24/2003 12:00am

    Originally posted by: Jonathan

    Any contributions are always nice. Thanks Senthil. It is hard to believe that others would criticize contributing when they themselves do nothing to contribute.

    jonathan

    Reply
  • Much more on http://www.smalleranimals.com/jpegfile.htm

    Posted by Legacy on 03/13/2003 12:00am

    Originally posted by: Manish Arora

    See http://www.smalleranimals.com/jpegfile.htm for greate jpeg library.
    

    Reply
  • I think This source has a bug in case of 32bit bitmap

    Posted by Legacy on 01/03/2003 12:00am

    Originally posted by: Jaeman Jo

    In DDBToDIB()

    Wrong: if( nColors > 256 ) nColors = 0;
    Right: if ( bi.biBitCount > 8 ) nColors = 0;

    Because previous line has a wrong shift operation.
    If bi.biBitCount is a 32, nColors becomes a one.

    int nColors = (1 << bi.biBitCount);

    Reply
  • Loading, Please Wait ...

Leave a Comment
  • Your email address will not be published. All fields are required.

Top White Papers and Webcasts

  • As all sorts of data becomes available for storage, analysis and retrieval - so called 'Big Data' - there are potentially huge benefits, but equally huge challenges...
  • The agile organization needs knowledge to act on, quickly and effectively. Though many organizations are clamouring for "Big Data", not nearly as many know what to do with it...
  • Cloud-based integration solutions can be confusing. Adding to the confusion are the multiple ways IT departments can deliver such integration...

Most Popular Programming Stories

More for Developers

RSS Feeds

Thanks for your registration, follow us on our social networks to keep up-to-date