Graphics and Multimedia Topics include: GDI+, drawing 2D/3D, printing and Managed DirectX and the XNA Framework

Go Back  Xtreme .NET Talk > .NET > Graphics and Multimedia > Transparent Controls over a Picture Box


Reply
 
Thread Tools Display Modes
  #1  
Old 01-19-2003, 05:23 PM
Dave Dave is offline
Newcomer
 
Join Date: Jan 2003
Posts: 23
Dave is on a distinguished road
Default Transparent Controls over a Picture Box

I have a picture box on my form (with an image in) and i want to put a label on top of it, but with the background of the label being transparent. It has to be a label control becuase it needs to be moved around at run-time in certain bits of code... any ideas?!?!?!
Reply With Quote
  #2  
Old 01-19-2003, 10:29 PM
Robby's Avatar
Robby Robby is offline
Ultimate Contributor
 
Join Date: Nov 2002
Location: Montreal, Ca.
Posts: 3,461
Robby is on a distinguished road
Default

You can just place an image in the label itself.
__________________
Visit...Bassic Software
Reply With Quote
  #3  
Old 01-20-2003, 04:15 AM
divil's Avatar
divil divil is offline
Ultimate Contributor
 
Join Date: Nov 2002
Location: England
Posts: 2,747
divil is on a distinguished road
Default

__________________
MVP, Visual Developer - .NET

Now you see why evil will always triumph - because good is dumb.

My free .NET Windows Forms Controls and Articles
Reply With Quote
  #4  
Old 01-20-2003, 08:51 AM
UCM's Avatar
UCM UCM is offline
Centurion

Preferred language:
VB.NET
 
Join Date: Dec 2002
Location: Colorado, usa
Posts: 135
UCM is on a distinguished road
Default

Hope this helps, I'm at work right now and away from my VB, please excuse any uncertainties but try this out...

It sounds like you want to put text on a background image kind of thing, like the text under the icons on your windows desktop...

If that's the case then you should ( i believe ) be able to do this with the designer...

In the designer, draw the label on top of the picture inside your picturebox. Use the designer's property tool-window on this label and click on the BackColor property.

This should open a lil window ontop of the backcolor property with 3 tabs, click on the 'Web' tab and scroll all the way up ( or down ) and you should see a transparent property...

Ither that or there might be a backstyle or backgound property to set to transparent.....
__________________
UCM
>-)
Reply With Quote
  #5  
Old 01-20-2003, 12:42 PM
Dave Dave is offline
Newcomer
 
Join Date: Jan 2003
Posts: 23
Dave is on a distinguished road
Default

Thanks 4 the link divil, setting the label's parent to the picture box worked fine.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Put a picture from a file, in a picture box... decrypt Graphics and Multimedia 5 05-28-2004 04:27 PM
Transparent Forms in J# ( Controls NOT Transparent ) dynamic_sysop Code Library 0 03-08-2004 04:02 PM
Transparent Background of a picture ToniMontana Graphics and Multimedia 2 03-05-2004 04:05 PM
Transparent Background on Picture Box kevinheeney Windows Forms 1 08-18-2003 05:52 AM
Delete Picture Box Picture hercemer Windows Forms 5 06-12-2003 07:04 AM

Advertisement:

Powered by liquidweb