473,503 Members | 1,654 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Enhancing Bob Powell example

Bob Powell has a code example called "Capturing the screen or the surface of
a control" found here:

http://www.bobpowell.net/capture.htm

I would like to know what in the world do I have to add to this code so that
the surface of the control is also captured even if there is another control
covering it.

Thank you. Please help!!!!!
May 20 '06 #1
3 1549
Rene,

I don't believe you can do that, unless you actually hide the control on
top of it. The windows manager knows the z order of the windows, and
doesn't have the window render that part of itself.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Rene" <a@b.c> wrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
Bob Powell has a code example called "Capturing the screen or the surface
of a control" found here:

http://www.bobpowell.net/capture.htm

I would like to know what in the world do I have to add to this code so
that the surface of the control is also captured even if there is another
control covering it.

Thank you. Please help!!!!!

May 20 '06 #2
I am looking at the DrawToBitmap() function inplemented by the Control class
and that funciton does return the complete surface even if there are
controls on top of it, how do they do that?

In case you are wondering why I don't use that functino if it already does
what I want is because the stupid Web Browser control has that function but
it does not work and of course the control that I need to snap-shot is a Web
Browser control.

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in
message news:OO**************@TK2MSFTNGP05.phx.gbl...
Rene,

I don't believe you can do that, unless you actually hide the control
on top of it. The windows manager knows the z order of the windows, and
doesn't have the window render that part of itself.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Rene" <a@b.c> wrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
Bob Powell has a code example called "Capturing the screen or the surface
of a control" found here:

http://www.bobpowell.net/capture.htm

I would like to know what in the world do I have to add to this code so
that the surface of the control is also captured even if there is another
control covering it.

Thank you. Please help!!!!!


May 20 '06 #3
Rene,

It appears that it creates a new bitmap and then gets the device context
for that bitmap. Then, what it does is call SendMessage, passing the handle
to the device context, as well as the WM_PRINT message, which tells the
control to draw itself to the device context.

Check out my response in an earlier thread (way earlier) which shows how
you can get the thumbnail image (of any size) from the WebBrowser control:

http://groups.google.com/group/micro...c571f730e13a25
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Rene" <a@b.c> wrote in message
news:eC**************@TK2MSFTNGP02.phx.gbl...
I am looking at the DrawToBitmap() function inplemented by the Control
class and that funciton does return the complete surface even if there are
controls on top of it, how do they do that?

In case you are wondering why I don't use that functino if it already does
what I want is because the stupid Web Browser control has that function
but it does not work and of course the control that I need to snap-shot is
a Web Browser control.

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote
in message news:OO**************@TK2MSFTNGP05.phx.gbl...
Rene,

I don't believe you can do that, unless you actually hide the control
on top of it. The windows manager knows the z order of the windows, and
doesn't have the window render that part of itself.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Rene" <a@b.c> wrote in message
news:%2****************@TK2MSFTNGP04.phx.gbl...
Bob Powell has a code example called "Capturing the screen or the
surface of a control" found here:

http://www.bobpowell.net/capture.htm

I would like to know what in the world do I have to add to this code so
that the surface of the control is also captured even if there is
another control covering it.

Thank you. Please help!!!!!



May 21 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1702
by: cognite | last post by:
This venue would surely appreciate the cool stuff being done in python on bioinformatics and python's tools for info parsing and extraction (like fulltext indexing, xml tools, parser builders,...
7
9262
by: Michael Foord | last post by:
#!/usr/bin/python -u # 15-09-04 # v1.0.0 # auth_example.py # A simple script manually demonstrating basic authentication. # Copyright Michael Foord # Free to use, modify and relicense. #...
3
2768
by: gizmo | last post by:
I have a stored procedure that queries a database using a Select statement with some inner joins and conditions. With over 9 million records it takes 1 min 36 sec to complete. This is too slow...
5
4707
by: relaxedrob | last post by:
Hi All! I ran the following w3c example through my WSDL parser (SOA Editor from Cape Clear): http://www.w3.org/TR/wsdl#_rpcexample It told me that there were a bunch of erros about no...
11
2621
by: ajikoe | last post by:
Hello, I used Visual C# Standard Edition. I want to comment my program using xml commentary method, I don't know why if I use value and example tag, it is not working / showed in the html...
9
1270
by: Dmitriy Zakharov | last post by:
Hi Everyone, You know how we have cache objects at different levels in ASP.NET. For example, there is one at application level (Cache) and one at user level (Session). How about having one...
7
1716
by: libsfan01 | last post by:
hi guys is there an extension for scriptaculous (or another library) that allows you to create more organic/natural looking movement? for example when an image slides across the screen, it...
0
759
by: Neville Dempsey | last post by:
What do I need to add to HTMLDecorator? A simpler example: import cgi class ClassX(object): pass # ... with own __repr__ class ClassY(object):
3
8460
by: amriksingh24 | last post by:
i have to write a function that given a graph G,produces a greedy colouring of vertices using welsh - powell algorithm
0
7198
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7319
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6979
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5570
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3160
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3149
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1498
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
730
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
373
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.