Results 1 to 6 of 6

Thread: How to get a label to the front of a pictureBox

  1. #1

    Thread Starter
    Hyperactive Member toughcoder's Avatar
    Join Date
    Nov 2002
    Location
    Near, Very Near
    Posts
    340

    Angry How to get a label to the front of a pictureBox

    Hi, I have a pictureBox and a lable on my usercontrol. I want to bring thelabel in front of the picturebox, which doesnt seems to be possible. When i select 'Bring to front' from the dit menu on the label, nothing happens. Similiarly, if I choose 'Send to back' on the pictureBox, its not going back. I want a way in which i can bring the label in front of the picturebox. I used the API BringWindowToTop, but it could also not solve the problem. Plz help.
    If Not VB Then Exit
    ------------------------------------------------
    visit me @ http://mzubair.50g.com/

  2. #2
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    I think it may be because labels don't have a hWnd, can you use a locked textbox instead? If not maybe you can make up your own label ActiveX?

  3. #3

    Thread Starter
    Hyperactive Member toughcoder's Avatar
    Join Date
    Nov 2002
    Location
    Near, Very Near
    Posts
    340

    Thanx Rick

    thanx Rick, but i got another alternate for my problem. Now I have pasted the label box inside the picturebox, aint that clever.
    If Not VB Then Exit
    ------------------------------------------------
    visit me @ http://mzubair.50g.com/

  4. #4
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    Oh yeah, I forgot you could do that

  5. #5
    Banished Cander's Avatar
    Join Date
    Dec 2000
    Location
    Why do you care?
    Posts
    6,913
    or you could have right clicked it and choose Bring To Front..
    Stack Overflow
    See the features of Visual Studio 2010 and C# 4.0: The 10-4 show on Channel9

  6. #6
    Frenzied Member Rick Bull's Avatar
    Join Date
    Apr 2002
    Location
    England
    Posts
    1,444
    He said in the first post it doesn't work for labels/pictures.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width