DIAdem Help

Object: PieChartSelectedElement

  • Updated2024-09-12
  • 1 minute(s) read

Object: PieChartSelectedElement

The PieChartSelectedElement object provides a selected element of a pie chart in DIAdem REPORT.

The following example checks whether elements of a pie chart are selected in the current worksheet and displays the name of the pie chart, the number of selected elements, and their type:

VBScriptPython

 

Dim oMyReportObj, oMyReportObjects, oMySelection, sOutput, I
Set oMyReportObjects = Report.ActiveSheet.Objects
For Each oMyReportObj in oMyReportObjects
  If oMyReportObj.ObjectType = eReportObjectPieChart Then
    Set oMySelection = oMyReportObj.SelectedElements
    sOutput = "Object name: " & oMyReportObj.Name & vbCrLf &_
              "Number of selected elements: " & oMySelection.Count & vbCrLf
    For I = 1 to oMySelection.Count
      sOutput = sOutput & "Element type: " & oMySelection.Item(i).Type & vbCrLf
    Next
    Call MsgBoxDisp(sOutput)
  End If
Next

Properties

Name | Type