Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Junior Member
 
Location: Northern NY USA
Posts: 3
Question Command Button Visibility

Hi folks.
I don't know how to make a Command Button visable only between specific dates. This Command Button will contain code to update members in my Volunteer Fire Department. I am in real need of an answer to this issue, even if it can't be done.
Thanks for your help
Keith
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,522
Default Command Button Visibility

On Feb 20, 5:37*pm, Excel_Fan <k b e r g 9 0 8 4 @ c h a r t e r . n e
t wrote:
Hi folks.
I don't know how to make a Command Button visable only between
specific dates. This Command Button will contain code to update members
in my Volunteer Fire Department. *I am in real need of an answer to this
issue, even if it can't be done.
Thanks for your help
Keith

--
Excel_Fan


I seldom use commang buttons. Assign your macro to a shape and place
this in the ThisWorkbook module

Private Sub Workbook_Open()
'MsgBox Date
If Date = DateSerial(2012, 2, 12) And _
Date < DateSerial(2012, 3, 12) Then
ActiveSheet.Shapes("Rectangle 1").Visible = True
Else
ActiveSheet.Shapes("Rectangle 1").Visible = False
End If
End Sub




  #3   Report Post  
Junior Member
 
Location: Northern NY USA
Posts: 3
Default

Quote:
Originally Posted by Don Guillett[_2_] View Post
On Feb 20, 5:37*pm, Excel_Fan <k b e r g 9 0 8 4 @ c h a r t e r . n e
t wrote:
Hi folks.
I don't know how to make a Command Button visable only between
specific dates. This Command Button will contain code to update members
in my Volunteer Fire Department. *I am in real need of an answer to this
issue, even if it can't be done.
Thanks for your help
Keith

--
Excel_Fan


I seldom use commang buttons. Assign your macro to a shape and place
this in the ThisWorkbook module

Private Sub Workbook_Open()
'MsgBox Date
If Date = DateSerial(2012, 2, 12) And _
Date < DateSerial(2012, 3, 12) Then
ActiveSheet.Shapes("Rectangle 1").Visible = True
Else
ActiveSheet.Shapes("Rectangle 1").Visible = False
End If
End Sub
Thanks Don,
I believe this will do what I want to do. The only other problem is that I want this to occur between Jan 1 and Jan 15 each year. I'm not sure how the code syntax should be entered to accomplish this. (I bought a book on VBA but I have difficulty grasping the formats, syntax and logic)
Thanks again.
KB
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,522
Default Command Button Visibility

On Thursday, March 1, 2012 11:07:18 PM UTC-6, Excel_Fan wrote:
'Don Guillett[_2_ Wrote:
;1447990']On Feb 20, 5:37*pm, Excel_Fan <k b e r g 9 0 8 4 @ c h a r t e
r . n e
t wrote:-
Hi folks.
I don't know how to make a Command Button visable only between
specific dates. This Command Button will contain code to update

members
in my Volunteer Fire Department. *I am in real need of an answer to


Try year(date)
DateSerial(year(date), 1, 1) And

this
issue, even if it can't be done.
Thanks for your help
Keith

--
Excel_Fan-


I seldom use commang buttons. Assign your macro to a shape and place
this in the ThisWorkbook module

Private Sub Workbook_Open()
'MsgBox Date
If Date = DateSerial(2012, 2, 12) And _
Date < DateSerial(2012, 3, 12) Then
ActiveSheet.Shapes("Rectangle 1").Visible = True
Else
ActiveSheet.Shapes("Rectangle 1").Visible = False
End If
End Sub


Thanks Don,
I believe this will do what I want to do. The only other problem is
that I want this to occur between Jan 1 and Jan 15 each year. I'm not
sure how the code syntax should be entered to accomplish this. (I
bought a book on VBA but I have difficulty grasping the formats, syntax
and logic)
Thanks again.
KB




--
Excel_Fan

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
Issue with command button visibility robs3131 Excel Programming 2 August 9th 07 01:14 PM
Visibility of a command Button Al Bundy Excel Programming 2 May 7th 04 10:59 PM
Visibility of a command Button Bob Phillips[_6_] Excel Programming 1 May 7th 04 10:46 PM
Visibility of a command Button Jake Marx[_3_] Excel Programming 0 May 7th 04 10:28 PM
Command Button Visibility Problem Ian[_9_] Excel Programming 2 February 20th 04 07:51 PM


All times are GMT +1. The time now is 10:14 PM.

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

About Us

"It's about Microsoft Excel"