Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Searcing for an Excel event.

Hi

I am working on a ADD-IN for excel.I have requirement as follows.

1) I have created a Excel command bar and created some command butttons on
it.
2) Button Start is a default command button which gets loaded with other
buttons and shown to the user (Visble=true) and other buttons are hidden
(visible=false).
3) The other buttons gets visible on some condtion i.e if a sheet named
mySettings gets loaded to the workbook then they will appear to the workbook
otherwise they will disapper (hideen).
4) I am searcing a event that will fire and search for the perticaulr sheet
in workbook and gets activate and deactivate the command buttons on the
command bar.

If i am missing something then plz let me know so that i can make it more
presise.

Thanks

__Das
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Searcing for an Excel event.

Here's an example


Public WithEvents App As Application

Private Sub App_SheetActivate(ByVal Sh As Object)

With Application.CommandBars("Worksheet Menu Bar").Controls("MyMenu")

.Controls("myButton").Visible = Sh.Name = "mySheet"
End With

End Sub

Private Sub Workbook_Open()
Set App = Application
End Sub

'This is workbook event code.
'To input this code, right click on the Excel icon on the worksheet
'(or next to the File menu if you maximise your workbooks),
'select View Code from the menu, and paste the code


--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"Dwipayan Das" wrote in message
...
Hi

I am working on a ADD-IN for excel.I have requirement as follows.

1) I have created a Excel command bar and created some command butttons
on
it.
2) Button Start is a default command button which gets loaded with other
buttons and shown to the user (Visble=true) and other buttons are hidden
(visible=false).
3) The other buttons gets visible on some condtion i.e if a sheet named
mySettings gets loaded to the workbook then they will appear to the
workbook
otherwise they will disapper (hideen).
4) I am searcing a event that will fire and search for the perticaulr
sheet
in workbook and gets activate and deactivate the command buttons on the
command bar.

If i am missing something then plz let me know so that i can make it more
presise.

Thanks

__Das



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
Searcing foran Excel event fired. Dwipayan Das Excel Worksheet Functions 1 July 7th 08 08:46 AM
apply cell change event to single column - WorksheetChange Event [email protected] Excel Programming 6 May 4th 08 02:28 AM
ad button for different rows after searcing in database tsumiki Excel Programming 0 April 11th 06 02:59 PM
Searcing throught using part of string bundyloco[_4_] Excel Programming 3 August 18th 05 08:01 PM
repost: searcing multi excel files... Scott Excel Programming 14 April 24th 05 04:51 PM


All times are GMT +1. The time now is 09:11 AM.

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"