How to place text over a picturebox

P

Phil Diwell

Hi all.

I am trying to place text over a picturebox. I thought I coul do this by
making the textbox.backcolor property = color.transparent.

However this doesn't work (textbox doesn't support transparent backcolor)
and so I am wondering if anyone knows how I can do this.

I need to be able to put multiple lines of text over the picturebox, so
using labels won't do it.

Any help would be appreciated.

Phil
 
J

Jon Davis

I don't know about textbox but label does support transparent background and
it also supports multiline text.

Jon
 
P

Phil

Hi, thanks for replying,

I just had a look and cannot find a multiline property for label, are you
sure there is one?
Maybe I'm missing something really obvious, but...

Phil
 
J

Jon Davis

It's multiline by default. The property editor doesn't support multiline
text, but if you pass a multiline string (containing "\r\n" per line break)
programmatically, it renders correctly.

Jon
 
P

Phil

Ah !!

Just tried it - you're right. I didn't know that (obviously)

I guess that solve my problem - thanks.

Phil
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top