We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to get the dropped measure name in OLAP Client?

Platform: ASP.NET Web Forms (Classic) |
Control: OlapClient

This KB illustrates that how to get the dropped measure name in OLAP Client.


You can get the dropped measure name in OLAP Client by using the following codes.


void OlapClient1_PreRender(object sender, EventArgs e)
            var measureNode = this.Page.Request.Form["__EVENTARGUMENT"];
            if (measureNode != null && measureNode.Contains("TreeNode___" + this.OlapClient1.OlapDataManager.CurrentCubeName + "\\\\Measures"))
                string[] items = measureNode.Split(new string[] { "\\", "_" }, StringSplitOptions.RemoveEmptyEntries);
                foreach (Syncfusion.Olap.Data.Measure measure in this.OlapClient1.OlapDataManager.CurrentCubeSchema.Measures)
                    if (measure.Caption == items[items.Count() - 1])
                        //// UniqueName of dropped MeasureElement
                        var respectiveUniqueName = measure.UniqueName;



Private Sub OlapClient1_PreRender(ByVal sender As Object, ByVal e As EventArgs)
   Dim measureNode = Me.Page.Request.Form("__EVENTARGUMENT")
   If measureNode IsNot Nothing AndAlso measureNode.Contains("TreeNode___" & Me.OlapClient1.OlapDataManager.CurrentCubeName & "\\Measures") Then
    Dim items() As String = measureNode.Split(New String() { "\", "_" }, StringSplitOptions.RemoveEmptyEntries)
    For Each measure As Syncfusion.Olap.Data.Measure In Me.OlapClient1.OlapDataManager.CurrentCubeSchema.Measures
     If measure.Caption = items(items.Count() - 1) Then
      '// UniqueName of dropped MeasureElement
      Dim respectiveUniqueName = measure.UniqueName
     End If
    Next measure
   End If
End Sub


You must log in to leave a comment

Please sign in to access our KB

This page will automatically be redirected to the sign-in page in 10 seconds.

Up arrow icon

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile