c# - Pivot Double Click - Show Detail event -


is there way can capture pivot double click event ? (the event generates detail view on sheet.)

is there way can see whole datasource of selected pivot datatable ?

i using c#, vsto programming.

here's how you'd in vba. put code in worksheet's code module:

private sub worksheet_beforedoubleclick(byval target range, cancel boolean) dim pt excel.pivottable  on error resume next set pt = target.pivottable if err.number = 0     msgbox "captured"     'to cancel uncomment next line     'cancel = true end if end sub 

edit: "i looking after double click event, need capture range of values on new sheet."

try then. put in thisworkbook module. uses module-level variable track whether pivot double-clicked , checks in newsheet event.

private pivotdoubleclicked boolean  private sub workbook_sheetbeforedoubleclick(byval sh object, byval target range, cancel boolean) dim pt excel.pivottable on error resume next set pt = target.pivottable if err.number = 0     pivotdoubleclicked = true end if end sub  private sub workbook_newsheet(byval sh object) if pivotdoubleclicked     msgbox "new sheet pivot double-click"     pivotdoubleclicked = false end if end sub 

Comments

Popular posts from this blog

java - Play! framework 2.0: How to display multiple image? -

gmail - Is there any documentation for read-only access to the Google Contacts API? -

php - Controller/JToolBar not working in Joomla 2.5 -