Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Lynn. Rickards
 
Posts: n/a
Default Problem setting BackStyle on Label

I have a problem with Properties on Label in particular, when added by
a script.

The sequence below works on CommandButton1 and Frame1 objects but
behaves
strangely with Label1

Public Sub addLabel()
Sheet2.OLEObjects.Add "Forms.Label.1", _
Left:=100, Top:=75, Height:=15, Width:=200
End Sub

Public Sub nameLabel()
Sheet2.Label1.Name = "title1"

End Sub

Public Sub setLabel()

Sheet2.title1.BackStyle = 0
Sheet2.title1.Caption = "My Text"
Sheet2.title1.Font.Bold = 1
Sheet2.title1.Font.Italic = 1
Sheet2.title1.Font.Size = 12
End Sub

The one property that doesn't have any effect on the appearance is
BackStyle

However, the value *is* set when I look at the object properties.
Changing it manually
in the properties dialog also has no visual effect - the label keeps
it's white background.

Now, if I add a Label manually, I can set BackStyle to 0 and it
immediately becomes
transparent.

What am I missing? By the way, I have the same behavior on excel 2000
and 2003
and on several different machines.

TIA - Lynn.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Text Truncated on Vertical Chart Axis Label Adrian Excel Discussion (Misc queries) 1 October 20th 05 12:50 PM
Identify Label €” More than one cell with label George Lynch Excel Discussion (Misc queries) 2 May 4th 05 06:12 PM
More than one cell with label Bob Frolek Excel Discussion (Misc queries) 0 April 25th 05 07:08 AM
Excel Display Problem Bill Martin -- (Remove NOSPAM from address) Excel Discussion (Misc queries) 0 April 19th 05 06:25 PM
Problem drawing lines on charts Susan Lambert Charts and Charting in Excel 7 December 13th 04 09:29 AM


All times are GMT +1. The time now is 01:21 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"