PC Review


Reply
Thread Tools Rate Thread

Changing the Caption on a Worksheet Label

 
 
New Member
Join Date: May 2006
Posts: 6
 
      18th May 2006
All of my books don't seem to address this issue. I have a map of the US that display's that I have added fifty labels to which display the percentage contained of each part of our portfolio. I have a table that links the label name to each state. I can't find the proper object to reference the caption value in order to have it automatically update when the table percentage value updates. Here's the code I was trying to use:

Activesheet.Shapes("Label" & Cells(S + X, Range("States").Column - 1).Value).Caption = Cells(S + X, Range("States").Column + 2).Value

I'm guessing that I shouldn't be using the Shapes object in this case? I can access many of the properties of "LabelX" with .Shapes but not the caption value. Thanks for your help!
 
Reply With Quote
 
 
 
 
New Member
Join Date: May 2006
Posts: 6
 
      18th May 2006
I reposted this topic in Programming.. but here's the progress I made anyway.. Please reply in the programming subforum.

Ok, so through the object browser/Debugging I know that I can directly reference the label object with Activesheet.label1 BUT, is there a way to dynamically access the label object?


So in other words, can I access it as Activesheet.Item("Label" & X) or something similar? I know Item isn't a member of the Worksheet object, but is there something there? Thanks again.
 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing a Label (Shapes) Caption Value on a Worksheet AhrenL Microsoft Excel Programming 1 18th May 2006 09:22 PM
changing label caption by user input =?Utf-8?B?anVsaWVqZzE=?= Microsoft Excel Programming 2 10th Apr 2006 10:01 PM
Label - Caption not changing Brian Hribek Microsoft Excel Programming 0 11th Oct 2004 10:02 PM
Label - Caption not changing Brian Hribek Microsoft Excel Programming 1 11th Oct 2004 09:19 PM
changing the caption of a label Koos Microsoft Excel Programming 4 18th Oct 2003 02:36 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:11 PM.