View Single Post
  #3   Report Post  
Saadi
 
Posts: n/a
Default

It Worked thanks Jimbola.

"Jimbola" wrote:

You can attach the function (macro) to the activate worksheet event for sheet
one.
In the visual basic editor click sheet1 on the left explorere window, then
in the code window on the right where the drop down list says declaration
change that to This Workbook, then on the right dropdown lists select
Activate.
Add your code and it should run when you click sheet1.

HTH

"Saadi" wrote:

Hi

I have a function, that is to be called when someone click on the sheet1.
can someone tell me how do I do this.

the name of that sub is FindRelatedVal()

Sub FindRelatedVal()
............................
End Sub