Manipulating section of a control 
Author Message
 Manipulating section of a control

Hello.
I have two controls, one on top of the other. I would like to try and
cut out a rectangle from the topmost control, and have the second
control display visible in this area.

I believe this can be done using the SetWindowRgn API function (among
others). Could someone point me towards an example that does this (or
something similar)? Or perhaps confirm that this is possible and I'm
not wasting my time?

Tips or advice are more than welcome, as well.

Thanks in advance,
R/mi.



Sat, 05 Feb 2005 00:51:49 GMT  
 Manipulating section of a control

Quote:
> I believe this can be done using the SetWindowRgn API function (among
> others). Could someone point me towards an example that does this (or
> something similar)? Or perhaps confirm that this is possible and I'm
> not wasting my time?

It is most certainly possible. The following URL points to an example of
using SetWindowRgn with a form, but of course it can be done with anything
that has a hWnd.
http://www.vbthunder.com/default.asp?srcget=4

What you'll need to do in your case is create two rectangular regions (using
the CreateRectRgn API), and then subtract the smaller from the larger using
CombineRgn.

--
Ben Baird
Visual Basic Thunder
http://www.vbthunder.com



Sat, 05 Feb 2005 01:15:50 GMT  
 Manipulating section of a control
Thanks Ben,
That's fantastic. Regions are a corner of the Windows API world I
haven't yet played around with, and this will go a long way towards
helping me learn.

Best regards,
R/mi.

Quote:



> > I believe this can be done using the SetWindowRgn API function (among
> > others). Could someone point me towards an example that does this (or
> > something similar)? Or perhaps confirm that this is possible and I'm
> > not wasting my time?

> It is most certainly possible. The following URL points to an example of
> using SetWindowRgn with a form, but of course it can be done with anything
> that has a hWnd.
> http://www.vbthunder.com/default.asp?srcget=4

> What you'll need to do in your case is create two rectangular regions (using
> the CreateRectRgn API), and then subtract the smaller from the larger using
> CombineRgn.



Sun, 06 Feb 2005 00:23:47 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Hide section header when section hidden

2. Section header behavior VB used to hide section

3. PDW [Bootstrap] section vs [Setup1 Files] section

4. manipulate ActiveX control in IE

5. Manipulating control on new document from template

6. Manipulating .Wav files or Voice Recorder Control With Playback

7. Manipulate controls in webforms with VB

8. manipulate PDF header (acrobat activex control)?

9. Need Help Manipulating a control on an Embedded Data Access Page

10. Can i manipulate ActiveX control thru VBScript?

11. control/manipulate external applications

12. Problem manipulating MonthView control with Page Up and Page Down keys

 

 
Powered by phpBB® Forum Software