I need to get the background image of a Panel that's on another form. I'm using this as a texture in a DX application. I cannot use "CopyFromScreen" as any other control that is over the top will be included in the captured image. Maybe one approach would be to make a copy of the Panels Background bitmap into memory to share with the other app - don't know how to do this in C#.
Or is there some GDI method?

Many thanks in advance.

Recommended Answers

All 4 Replies

You have some foggy spots, lets clarify.

is it 2 separate applications, or 2 different forms in the same application?

If it is 2 separate apps, are they both written by you and are editable?

Sorry. I have a DX exe (no form) that sits in memory and renders to a panel on a form (form has a background image) some scrolling text....works great! However, I need to get a copy of what is in the panel background so that the DX application can use this as a background texture to render the scrolling text over. I have control of all apps. I can't work out the best approach. Even thought clipboard...that seems a bit of a cludge, however.

Im not sure why you are using 2 executable for this. why not write a control that does its own scrolling text? not very difficult.

but you can easily create an event that when the background image of the panel changes just save it do disk and read it with the other application.


but why do you need 2 apps for this?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.