彩票走势图

DevExpress通过XMLA绑定 PivotGridControl 到OLAP多维数据集

转帖|其它|编辑:郝浩|2012-10-17 16:40:25.000|阅读 359 次

概述:之前我们已经介绍了如何用 ADOMD.NET Data Provide绑定 PivotGridControl 到OLAP多维数据集,接下来,我们换XMLA,具体代码事例如下:

# 慧都年终大促·界面/图表报表/文档/IDE等千款热门软控件火热促销中 >>

之前我们已经介绍了如何用 ADOMD.NET Data Provide绑定 PivotGridControl 到OLAP多维数据集,接下来,我们换XMLA,具体代码事例如下:

C#

using System;
using System.Windows.Forms;
using DevExpress.XtraPivotGrid;

namespace XtraPivotGrid_XMLA {
    public partial class Form1 : Form {
        public Form1() {
            InitializeComponent();
        }
        void Form1_Load(object sender, EventArgs e) {

            // Specifies that PivotGridControl should use the XMLA data access standard
            // to bind to an OLAP cube.
            pivotGridControl1.OLAPDataProvider = OLAPDataProvider.Xmla;

            // Configures a data connection.
            // Specifies a string that encapsulates connection parameters 
            // required to access the desired OLAP cube.
            pivotGridControl1.OLAPConnectionString = 
                "Data Source=//demos.devexpress.com/Services/OLAP/msmdpump.dll;" +
                "Initial Catalog=Adventure Works DW Standard Edition;Cube Name=Adventure Works";
        }
    }
}

VB

Imports Microsoft.VisualBasic
Imports System
Imports System.Windows.Forms
Imports DevExpress.XtraPivotGrid

Namespace XtraPivotGrid_XMLA
    Partial Public Class Form1
        Inherits Form
        Public Sub New()
            InitializeComponent()
        End Sub
        Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Load

            ' Specifies that PivotGridControl should use the XMLA data access standard
            ' to bind to an OLAP cube.
            pivotGridControl1.OLAPDataProvider = OLAPDataProvider.Xmla

            ' Configures a data connection.
            ' Specifies a string that encapsulates connection parameters 
            ' required to access the desired OLAP cube.
            pivotGridControl1.OLAPConnectionString = _
                "Data Source=//demos.devexpress.com/Services/OLAP/msmdpump.dll;" & _
                "Initial Catalog=Adventure Works DW Standard Edition;Cube Name=Adventure Works"
        End Sub
    End Class
End Namespace


标签:DevExpressOLAP

本站文章除注明转载外,均为本站原创或翻译。欢迎任何形式的转载,但请务必注明出处、不得修改原文相关链接,如果存在内容上的异议请邮件反馈至chenjj@cahobeh.cn

文章转载自:慧都控件网

为你推荐

  • 推荐视频
  • 推荐活动
  • 推荐产品
  • 推荐文章
  • 慧都慧问
相关产品
DevExpress Universal Subscription

行业领先的界面控件开发包,帮助企业构建卓越应用!

DevExpress WPF Subscription

高效MVVM开发模式,WPF界面解决方案首选工具,帮助企业实现酷炫动效界面。

DevExpress Silverlight Controls

高性价比高实用性的Silverlight用户界面控件套包,拥有大量的示例和帮助文档,开发者能够快速上手!

DevExpress WinForms Subscription

为Windows Forms平台创建具有影响力的业务解决方案,高性价比WinForms界面控件套包。

DevExpress DXperience Subscription

高性价比的企业级.NET用户界面套包,助力企业创建卓越应用!

title
扫码咨询


添加微信 立即咨询

电话咨询

客服热线
023-68661681

TOP