select chart point trigger macro

Dirt

New Member
Joined
Jun 17, 2008
Messages
7
Can I select a point on a chart and have it trigger a macro? (pop up, etc.) for example on a control chart. I would like to click the point beyond control limits and have it trigger a macro that allows annotation.
TIA,

D
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.

pgc01

MrExcel MVP
Joined
Apr 25, 2006
Messages
19,891
Hi Dirt
Welcome to the board

Yes you can. You can use the chart events, directly in the case of a chart sheet, or enable them in the case of an embedded chart.

In the case you describe, you can use the MouseDown() event. It will give you the location of the mouse click and you can then do whatever you want.

You must be able to program in vba.

You can read this ms article, that explains how to do it (click also inside in "Chart Object Events") :

http://msdn.microsoft.com/en-us/library/bb211434.aspx


For a detailed explanation, you have this Jon Peltier article, where he explains step by step how to do it:

http://www.computorcompanion.com/LPMArticle.asp?ID=221
 
Upvote 0

Forum statistics

Threads
1,190,565
Messages
5,981,707
Members
439,732
Latest member
TC_vii

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top