VB.NET - off-screen toughie - HELP!!!

  • Thread starter Thread starter Dogmatixy
  • Start date Start date
D

Dogmatixy

Hi all,

I'm searching for something similar to what there used to be in QBasic
etc.
There was an option to define a "visual page" and an "Active page",
where the visual one was what we saw on the screen, and the active one
was where we could do anything without it being seen on the screen,
and afterwards pass it to the screen, in other words we could prepare
forms, make changes, and only after it was all ready we could pass it
to our viewing screen.
If there is anyway to define a screen buffer,or something similar.

The reason I want this is in order to make a picture of a form,
without showing it on the screen.
I saw on the net a lot regarding screen capturing and using
CreateGraphics, but the down side is:
- When you capture screen, you need to see what you are capturing, but
I want it to be done without the objects being visible
- When using the CreateGraphics option, you can only draw graphics,
but not forms or tables.

PLEASE HELP ME.

Yours truely,
Dogmatixy.
 
Hi Dogmatixy,

You can set the visible property to a Form to False, and then make all the
changes you want. When you're done with your changes, set the Visible
property to True. I'm not sure this meets your need; perhaps I need more
specifics about what you're trying to do. The low level solution you
discuss (using a buffer) may be difficult to translate to a form.

Craig
VB.Net Team
 
Thanks for answering, however I ment something else:
Creating the form is one thing, which we all know how to do, visibly
or invesibly, but I am talking about turning this form into an
image(Bitmap,JPG, Gif, or even image objects in VB such as Bitmap and
Image) without making the form visible.
For instance, let's say you want to make a form appear in a special
way, such as from far to close, spinning etc. One thing you could do
is create the form, show it, make a screen capture of it, and then
turn it into a bmp or jpg picture, and only then start manipulating
its appearance, but I want to cut the inbetween part, where I have to
show the form, and make a screen capture of it, amd jump to the last
part.

Dogmatixy.
 
Thanks for answering, however I ment something else:
Creating the form is one thing, which we all know how to do, visibly
or invesibly, but I am talking about turning this form into an
image(Bitmap,JPG, Gif, or even image objects in VB such as Bitmap and
Image) without making the form visible.
For instance, let's say you want to make a form appear in a special
way, such as from far to close, spinning etc. One thing you could do
is create the form, show it, make a screen capture of it, and then
turn it into a bmp or jpg picture, and only then start manipulating
its appearance, but I want to cut the inbetween part, where I have to
show the form, and make a screen capture of it, amd jump to the last
part.

Dogmatixy.

I don't have any code - nor is my area of expertice in graphics - but
couldn't you get a bitmap image of the form from it's graphics object,
and then use the API to draw the image to the desktop? That would allow
you to not make the form visible, just create it, get the graphics
object, draw to it, grap the image and blit it to the desktop window.

I know it wouldn't be exactly simple to code - but that seems to be the
logical process to do what you want. Anyway, just a thought :)
 
Thank's, I'd like to see that code.
However, we must understand that drawing everything can take up some
CPU and time, I just hoped that there could be a simple way such as an
invisible buffer etc.
But any other solution would be much obliged.

Dogmatix.
 
Back
Top