[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 192
  • Last Modified:

labels on pictures

I want to put a label in front of a picturebox and have tried setting the zorder of the label to 0 to put it in front. but this does not work can I do this any other way
0
James_stillman
Asked:
James_stillman
1 Solution
 
deightonCommented:
Yes Add your picture box in design mode then draw a label over the top of it.
0
 
deightonCommented:
In your .frm code in ascii format in note pad it shouldl then look  something like

  Begin VB.PictureBox Picture1
      Height          =   1695
      Left            =   1440
      Picture         =   "TEST.frx":0000
      ScaleHeight     =   1635
      ScaleWidth      =   3795
      TabIndex        =   0
      Top             =   600
      Width           =   3855
      Begin VB.Label Label1
         Caption         =   "Label1"
         Height          =   375
         Index           =   0
         Left            =   1800
         TabIndex        =   1
         Top             =   480
         Width           =   1215
      End
   End
0
 
VbmasterCommented:
In design time, select the label, use Ctrl+X to cut it out, select the picturebox, use Ctrl-V to paste it. Voilá.
0
 
caraf_gCommented:
Indeedy.

And the reason is that labels and other windowless controls cannot be z-ordered in front of windowed controls.

Just thought you'd be interested in that little snippet of useless (?) information.
0
 
James_stillmanAuthor Commented:
Hey I don't know who to give the points to cos dieghton basically said the same as VBMaster, but did it in code.

An cheers caraf_q for the comment, Pretty useful i'd say I knew that I could put a label inside a picture box control, but didn't know why I couldn't place the label in front of the picture box, Cheers.

I reckon it's going to have to be deighton, cod he ansewered first.
 Cheers for the help Guys

James
0

Featured Post

The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now