LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,824
Default command button and assign macro

That's not what I meant--but may have been what I wrote!

I meant that you'd need different code depending on what type of buttons you
used to disable/hide the button.

And if you disable/hide either of the buttons, then you won't be able to click
on that button to toggle it back to enabled/visible. You'll need some other way
to turn it back on--another button with code that points at that other button.

And just in case, I meant that you could choose to disable the button or hide
it. You don't need to do both.



"RichardO <" wrote:

Wow, thanks much for your explanations, Dave:

For your response to #4, are you saying that if I want to disable/hide
and then enable/unhide the button, I should only use the Forms toolbar
(and not the controlbox toolbar) and the following code will disable
and then enable the button later on?

Option Explicit
Sub testme01()
MsgBox "Yo"
With ActiveSheet.Buttons(Application.Caller)
Enabled = True
'or
Visible = False
End With
End Sub

Richardo

---
Message posted from http://www.ExcelForum.com/


--

Dave Peterson

 
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
how do you assign a macro to a command button in Excel 2003 ns Excel Discussion (Misc queries) 5 October 25th 07 08:58 PM
Assign a macro to a command button SheriTingle Excel Discussion (Misc queries) 4 September 25th 06 06:38 PM
Assign a macro to Command Button Object dallin Excel Discussion (Misc queries) 2 July 13th 05 03:50 AM
How do I assign a macro I have created to a Command Button in Exc. Andrew7675 Excel Discussion (Misc queries) 1 March 3rd 05 08:08 PM
Assign Macro to Command Button Shunt Excel Programming 1 August 7th 03 02:07 PM


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