Label background color?

rfresh

Well-Known Member
Licensed User
Longtime User
Is there a Label background color property? I didn't see one in the Designer.

Thanks...
 
label background color

Is there a Label background color property? I didn't see one in the Designer.

Thanks...

yes it is,
Code:
label1.color = colors.transparent   'if you want the label to be transparent.
label1.textcolor = colors.blue   'color of text

cheers,
Walter
 
Upvote 0
I didn't see one in the Designer.

Look at the attached Designer screenshot.
 

Attachments

  • Shot.JPG
    Shot.JPG
    57.7 KB · Views: 1,164
Upvote 0
Hmmm...I'm doing the following and I don't see any changes in the colors of this Label

Code:
lbl_website.Color = Colors.Cyan
lbl_website.TextColor = Colors.Red

I also tried setting it in the Designer but it didn't take there either. When I ran my app the Label was still White text on a Black background.
 
Upvote 0
BTW I wasn't able to set the BG color of a label in code because I couldn't set the .Alpha color.

Code:
lbl_setup_Title.Color = Colors.Cyan
lbl_setup_Title.TextColor = Colors.Red
lbl_setup_Title.Alpha = 114

...third line did not compile...
 
Upvote 0
Gosh, I would have never figured out that syntax.

Code:
lbl_setup_Title.TextColor = Colors.Red
lbl_setup_Title.Color = Colors.ARGB(120, 255, 255, 0)

So I'm trying for a Yellow background with Red text via the above code. Unfortunately, it doesn't work as the colors don't change. So I guess I'm still doing something wrong?
 
Upvote 0
Back
Top