Reputation: 19
By using the below code I created a Shape in Visual studio Tools for Office
private void Sheet01_Startup(object sender, System.EventArgs e) {
this.Shapes.AddShape(Office.MsoAutoShapeType.msoShapeActionButtonCustom, 160, 461, 109, 20);
}
I want do some thing when I click on the shape.
Please help me to write events for this.
Upvotes: 0
Views: 95
Reputation: 49455
VSTO doesn't provide anythig for that.
If you are talking about an Excel add-in, the Shape class doesn't provide any event for that. I bielive you may find the SelectionChange event of the Worksheet class helpful. It is fired when the selection changes on a worksheet. So, you can check out the select object on sheet.
Upvotes: 0