Hello. I am trying to run a macro upon the selection of a chart sheet. I can successfully run a macro upon selection of a worksheet by putting the following code on the worksheet module:
Private Sub Worksheet_Activate()
MsgBox "WARNING: To paste your data, please use the PASTE MY DATA BUTTON on row 9. DO NOT use any other method of pasting your data. Please press Ok."
End Sub
However, when I try to do the same with a Chart Sheet (sheet with embedded pivot chart), the code does not work. I believe this is because a sheet with an embedded chart.
I tried to put the following code in the Sheet code of the chart worksheet:
Private Sub Sheet_Activate()
ActiveChart.DeSelect
End Sub
I need to be able to deselect the active chart when the chart sheet is selected.
Any idea? Thanks in advance!!
mcbien
Private Sub Worksheet_Activate()
MsgBox "WARNING: To paste your data, please use the PASTE MY DATA BUTTON on row 9. DO NOT use any other method of pasting your data. Please press Ok."
End Sub
However, when I try to do the same with a Chart Sheet (sheet with embedded pivot chart), the code does not work. I believe this is because a sheet with an embedded chart.
I tried to put the following code in the Sheet code of the chart worksheet:
Private Sub Sheet_Activate()
ActiveChart.DeSelect
End Sub
I need to be able to deselect the active chart when the chart sheet is selected.
Any idea? Thanks in advance!!
mcbien