LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 93
Default button name scope and Caption

I have a main sheet that I replicate as 'what if' versions. There are
no collisions with any names on these copies since all code refers to
them in the context of the sheet.

Except for buttons and their attribute Caption.

There is one these buttons that has it's caption changed ('Show',
'Hide') but even within the context of the current sheet, it fails.

wS.Buttons("button_show_hide").Caption = "Hide"

What is REALLY strange is that the caption seems to be changing
somewhere, because the decision to Show or Hide is based on the
following. Again, this is successful:

StrComp(wS.Buttons("button_show_hide").Caption, "Hide")

The main sheet, from which all these 'What if's are copied, it's
button continues to work just fine. The caption toggles.

Anyone have an idea how to fix this?
 
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
Set Button Caption Nigel Excel Programming 1 February 2nd 09 09:58 PM
How to set up caption on a button at startup? [email protected] Excel Programming 6 November 21st 07 11:01 PM
Change Caption of Button Alexander Excel Programming 3 August 17th 05 04:45 PM
Caption of a button Dr_Phil Excel Programming 4 May 4th 04 09:13 PM
Custom Button Scope Limitation RonF Excel Programming 1 February 27th 04 02:43 PM


All times are GMT +1. The time now is 07:01 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"