Results 1 to 5 of 5

Thread: I have asked something before

  1. #1

    Thread Starter
    PowerPoster abdul's Avatar
    Join Date
    Dec 2000
    Location
    Ontario,Canada
    Posts
    2,827

    I have asked something before

    I have asked similiar question before but did not get a good answer.

    I am trying to take a screenshot of the desktop and it is working fine when I put that on my main window. But I want to put that in a spicifc place like a picture box. But there is no picture box in C++ so which control do I use to copy the contents of dektop onto that control?

    And then after that, I want to save the contents on that control to a file as a bitmap. Who do I do that?
    Baaaaaaaaah

  2. #2
    transcendental analytic kedaman's Avatar
    Join Date
    Mar 2000
    Location
    0x002F2EA8
    Posts
    7,221
    You can simply bitblt over the screen DC to a memory DC and then onto any window's DC. for saving, I've made a save algoritm, i'll see if i can find it
    Use
    writing software in C++ is like driving rivets into steel beam with a toothpick.
    writing haskell makes your life easier:
    reverse (p (6*9)) where p x|x==0=""|True=chr (48+z): p y where (y,z)=divMod x 13
    To throw away OOP for low level languages is myopia, to keep OOP is hyperopia. To throw away OOP for a high level language is insight.

  3. #3
    Frenzied Member Vlatko's Avatar
    Join Date
    Aug 2000
    Location
    Skopje, Macedonia
    Posts
    1,409
    If you are using a dialog then just draw a oic box on it.
    I am become death, the destroyer of worlds.
    mail:[email protected]

    • Visual Basic 6.0 & .NET
    • Visual C++ 6.0 & .NET
    • ASP
    • LISP
    • PROLOG
    • C
    • Pascal

  4. #4
    Megatron
    Guest
    If you want to use a control, then use a Static control, otherwise, but I strongly agree with kedaman that you should use a memory DC.

  5. #5

    Thread Starter
    PowerPoster abdul's Avatar
    Join Date
    Dec 2000
    Location
    Ontario,Canada
    Posts
    2,827
    So if I use the memory DC but when I still want to show the screenshot to the user before saving, then I need a kind of contro, right? So the static control will work and do I need to subclass it to recieve a WM_PAINT message, or does it never recieve WM_PAINT message?
    Baaaaaaaaah

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width