Hello,
When i insert a "Label" on a UserForm it automatically gets a "Name" and matching "Caption", i.e. "Label1". Can i use find/replace or something else to rename these all at once? Say, find "Label" change to "LBL".
Thank you,
Stefan
autoreplace "label" name in UserForm
-
-
-
Re: autoreplace "label" name in UserForm
AFAIK yo can't change the Name property like that, you could the caption
-
Re: autoreplace "label" name in UserForm
Only in the code Event Procedures you already have. Why not simply rename each one when you add it?
-
Re: autoreplace "label" name in UserForm
Hi,
QuoteAFAIK yo can't change the Name property like that, you could the caption
Thank you. Although i already changed all 100+ names and captions last night manually, if you could please point out how the captions can be changed all at once would be appreciated. I'm sure it can come handy.
QuoteWhy not simply rename each one when you add it?
Yeah, easier said... The project was set-up and used one way. Now it canged and got added a bunch of extra data and hence wanted to rename existing ones to fit better in the bigger picture.
Stefan
-
Re: autoreplace "label" name in UserForm
Stefan
Why do you have 100 labels?
What would they be renamed as, and how would you tell which label to renamed as what?
-
-
Re: autoreplace "label" name in UserForm
You can loop through the labels and change the caption, but as Norie says what would you change them to?
-
Re: autoreplace "label" name in UserForm
Hello,
Okay i suppose that someones "right" way is another ones "wrong" way.
The labels have data throught a workbook to present a report. This started with a couple here and a couple there, and now there are 100 labels.
The labels have sort of a unique references and my thought was that a find/replace could help in renaming them. Say, find "Label1" (which is in the strings from "Label101" through "Label131") and replace it with "Count1". This would result in the change to Count101 through Count131. The same could be dones with the Labels2xx, Labels3x and the Lables4x - so i thought.
Stefan
p.s.
Since i did this already manually, i think i better consider this resolved.
Participate now!
Don’t have an account yet? Register yourself now and be a part of our community!