当前位置: 首页>>代码示例>>C#>>正文


C# DevExpress.DataBind方法代码示例

本文整理汇总了C#中DevExpress.DataBind方法的典型用法代码示例。如果您正苦于以下问题:C# DevExpress.DataBind方法的具体用法?C# DevExpress.DataBind怎么用?C# DevExpress.DataBind使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DevExpress的用法示例。


在下文中一共展示了DevExpress.DataBind方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: CarregarASPxGridView

 public static void CarregarASPxGridView( DevExpress.Web.ASPxGridView.ASPxGridView aspxgridview, System.Data.DataTable table)
 {
     aspxgridview.AutoGenerateColumns = true;
     aspxgridview.DataSource = table;
     //aspxgridview.KeyFieldName = "#";
     aspxgridview.DataBind();
 }
开发者ID:EmersonBessa,项目名称:FluxusWeb,代码行数:7,代码来源:Util.cs

示例2: RefreshGrid

 private void RefreshGrid(DevExpress.Web.ASPxGridView.ASPxGridView gv)
 {
     gv.DataSource = Business.MediosPublicitarios.ReadAllGrupo("");
     gv.DataBind();
 }
开发者ID:javierlov,项目名称:PautasElectronica,代码行数:5,代码来源:GruposMediosPublicitarios.aspx.cs

示例3: InitListPhieuYeuCau

        public static void InitListPhieuYeuCau(DevExpress.Web.ASPxGridLookup.ASPxGridLookup gridLookup, bool? IsAdd)
        {
            //DevExpress.Web.ASPxGridView.GridViewDataTextColumn colMa = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            //colMa.Caption = "Mã dự án";
            //colMa.FieldName = DA_DU_AN.cl_MA_DU_AN;
            DataTable dtYC = YC_YEU_CAU.GetTable(@"SELECT yc.YEU_CAU_ID,
            yc.TIEU_DE,yc.NGAY_YEU_CAU,
            lyc.TEN_LOAI_YC,
            ttyc.[NAME] TRANG_THAI_YC,
            nd.[NAME] NGUOI_YC,yc.NGUOI_YEU_CAU
            FROM YC_YEU_CAU yc
            LEFT JOIN ND_THONG_TIN_ND nd ON nd.ID=yc.NGUOI_YEU_CAU
            LEFT JOIN YC_DM_LOAI_YEU_CAU lyc ON lyc.ID=yc.LOAI_YC_ID
            LEFT JOIN YC_DM_TRANG_THAI_YEU_CAU ttyc ON ttyc.ID = yc.TRANG_THAI_ID", YC_YEU_CAU.sTableName
            );
            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colTieuDe = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colTieuDe.Caption = "Phiếu yêu cầu";
            colTieuDe.FieldName = YC_YEU_CAU.cl_TIEU_DE;

            DevExpress.Web.ASPxGridView.GridViewDataDateColumn colNgayYC = new DevExpress.Web.ASPxGridView.GridViewDataDateColumn();
            colNgayYC.Caption = "Ngày yêu cầu";
            colNgayYC.FieldName = YC_YEU_CAU.cl_NGAY_YEU_CAU;

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colNguoiYC = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colNguoiYC.Caption = "Người yêu cầu";
            colNguoiYC.FieldName = "NGUOI_YC";

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colLoaiYC = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colLoaiYC.Caption = "Loại yêu cầu";
            colLoaiYC.FieldName = "TEN_LOAI_YC";

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colTTYC = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colLoaiYC.Caption = "Trạng thái";
            colLoaiYC.FieldName = "TRANG_THAI_YC";

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colID = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colID.Caption = "ID";
            colID.FieldName = YC_YEU_CAU.cl_YEU_CAU_ID;
            colID.Visible = false;

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colNguoiYCID = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colNguoiYCID.Caption = "NGUOI_YC_ID";
            colNguoiYCID.FieldName = YC_YEU_CAU.cl_NGUOI_YEU_CAU;
            colNguoiYCID.Visible = false;

            gridLookup.Columns.Clear();
            gridLookup.Columns.Add(colTieuDe);
            gridLookup.Columns.Add(colNgayYC);
            gridLookup.Columns.Add(colNguoiYC);
            gridLookup.Columns.Add(colLoaiYC);
            gridLookup.Columns.Add(colTTYC);
            gridLookup.Columns.Add(colID);
            gridLookup.Columns.Add(colNguoiYCID);
             //   gridLookup.GridView.Settings.ShowFilterRow = true;
            AddEmptyRow(dtYC, YC_YEU_CAU.cl_YEU_CAU_ID);
            gridLookup.DataSource = dtYC;
            gridLookup.KeyFieldName = YC_YEU_CAU.cl_YEU_CAU_ID;
            gridLookup.DataBind();
        }
开发者ID:khanhdtn,项目名称:scmct-2012,代码行数:59,代码来源:functions.cs

示例4: InitListDuAn

        public static void InitListDuAn(DevExpress.Web.ASPxGridLookup.ASPxGridLookup gridLookup, bool? IsAdd)
        {
            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colMa = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colMa.Caption = "Mã dự án";
            colMa.FieldName = DA_DU_AN.cl_MA_DU_AN;

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colTenDA = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colTenDA.Caption = "Tên dự án";
            colTenDA.FieldName = DA_DU_AN.cl_TEN_DU_AN;

            DevExpress.Web.ASPxGridView.GridViewDataDateColumn colNgayTao = new DevExpress.Web.ASPxGridView.GridViewDataDateColumn();
            colNgayTao.Caption = "Ngày tạo";
            colNgayTao.FieldName = DA_DU_AN.cl_NGAY_TAO;

            DevExpress.Web.ASPxGridView.GridViewDataDateColumn colNgayBD = new DevExpress.Web.ASPxGridView.GridViewDataDateColumn();
            colNgayBD.Caption = "Ngày bắt đầu";
            colNgayBD.FieldName = DA_DU_AN.cl_NGAY_BAT_DAU;

            DevExpress.Web.ASPxGridView.GridViewDataDateColumn colNgayKT = new DevExpress.Web.ASPxGridView.GridViewDataDateColumn();
            colNgayKT.Caption = "Ngày kết thúc";
            colNgayKT.FieldName = DA_DU_AN.cl_NGAY_KET_THUC;

            DataTable dtTrangThai = DA_DM_TRANG_THAI_DU_AN.GetTableAll();
            DevExpress.Web.ASPxGridView.GridViewDataComboBoxColumn colTrangThai = new DevExpress.Web.ASPxGridView.GridViewDataComboBoxColumn();
            colTrangThai.PropertiesComboBox.DataSource = dtTrangThai;
            colTrangThai.PropertiesComboBox.ValueField = DA_DM_TRANG_THAI_DU_AN.cl_ID;
            colTrangThai.PropertiesComboBox.TextField = DA_DM_TRANG_THAI_DU_AN.cl_NAME;
            colTrangThai.Caption = "Trạng thái dự án";
            colTrangThai.FieldName = DA_DU_AN.cl_TRANG_THAI_ID;

            DevExpress.Web.ASPxGridView.GridViewDataTextColumn colID = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
            colID.Caption = "ID";
            colID.FieldName = DA_DU_AN.cl_ID;
            colID.Visible = false;

            gridLookup.Columns.Clear();
            gridLookup.Columns.Add(colMa);
            gridLookup.Columns.Add(colTenDA);
            gridLookup.Columns.Add(colNgayTao);
            gridLookup.Columns.Add(colNgayBD);
            gridLookup.Columns.Add(colNgayKT);
            gridLookup.Columns.Add(colTrangThai);
            gridLookup.Columns.Add(colID);

              //  gridLookup.GridView.Settings.ShowFilterRow = true;

            DataTable dtDA= DA_DU_AN.GetTableAll();
            AddEmptyRow(dtDA, DA_DU_AN.cl_ID);
            gridLookup.DataSource = dtDA;
            gridLookup.KeyFieldName = DA_DU_AN.cl_ID;
            gridLookup.DataBind();
        }
开发者ID:khanhdtn,项目名称:scmct-2012,代码行数:52,代码来源:functions.cs

示例5: InitGridLookup

        public static void InitGridLookup(DevExpress.Web.ASPxGridLookup.ASPxGridLookup gridLookup,
            DataTable dtSource, string ValueField, string DisplayField, string[] Columns, string[] Caption)
        {
            AddEmptyRow(dtSource, ValueField);
            if (Columns != null && Columns.Length > 0)
            {
                if (Caption == null) Caption = new string[0];

                for (int i = 0; i < Columns.Length; i++)
                {
                    DevExpress.Web.ASPxGridView.GridViewDataTextColumn col = new DevExpress.Web.ASPxGridView.GridViewDataTextColumn();
                    col.Caption = i < Caption.Length ? Caption[i] : Columns[i];
                    col.FieldName = Columns[i];
                    gridLookup.Columns.Add(col);

                }
            }
            gridLookup.KeyFieldName = ValueField;

            gridLookup.DataSource = dtSource;
            gridLookup.DataBind();
        }
开发者ID:khanhdtn,项目名称:scmct-2012,代码行数:22,代码来源:functions.cs

示例6: InitCombobox

 /// <summary>
 /// Khởi tạo datasoucre cho control ASPxComboBox
 /// </summary>
 /// <param name="cbo"></param>
 /// <param name="dtSource"></param>
 /// <param name="ValueField"></param>
 /// <param name="DislpayField"></param>
 public static void InitCombobox(DevExpress.Web.ASPxEditors.ASPxComboBox cbo,
     DataTable dtSource, string ValueField, string DislpayField)
 {
     AddEmptyRow(dtSource, ValueField);
     cbo.DataSource = dtSource;
     cbo.ValueField = ValueField;
     cbo.TextField = DislpayField;
     cbo.DataBind();
 }
开发者ID:khanhdtn,项目名称:scmct-2012,代码行数:16,代码来源:functions.cs

示例7: UpdateEventChart

 private void UpdateEventChart(DevExpress.XtraCharts.Web.WebChartControl wc, int rsch)
 {
     int r = rsch;
     int virtualTime = 0;
     wc.Series.Clear();
     var evts = ResearchManager.GetEventsSignByRschId(r);
     ArrayList fDS = new ArrayList();
     ArrayList rDS = new ArrayList();
     ArrayList pDS = new ArrayList();
     ArrayList sDS = new ArrayList();
     foreach (var evt in evts)
     {
         virtualTime++;
         switch (evt.module)
         {
             case 1:
                 fDS.Add(new Record(virtualTime, evt.significance, evt.significance + 1));
                 break;
             case 2:
                 rDS.Add(new Record(virtualTime, evt.significance, evt.significance + 1));
                 break;
             case 3:
                 pDS.Add(new Record(virtualTime, evt.significance, evt.significance + 1));
                 break;
             case 4:
             case 5:
                 sDS.Add(new Record(virtualTime, evt.significance, evt.significance + 1));
                 break;
         }
     }
     Series fseries = new Series("Файловая система", ViewType.SideBySideRangeBar);
     Series rseries = new Series("Реестр", ViewType.SideBySideRangeBar);
     Series pseries = new Series("Процессы", ViewType.SideBySideRangeBar);
     Series sseries = new Series("Сеть", ViewType.SideBySideRangeBar);
     wc.Series.Add(fseries);
     wc.Series.Add(rseries);
     wc.Series.Add(pseries);
     wc.Series.Add(sseries);
     ((SideBySideRangeBarSeriesView)fseries.View).Color = Color.FromArgb(75, 89, 97);
     ((SideBySideRangeBarSeriesView)fseries.View).FillStyle.FillMode = FillMode.Solid;
     ((SideBySideRangeBarSeriesView)rseries.View).Color = Color.FromArgb(37, 119, 147);
     ((SideBySideRangeBarSeriesView)rseries.View).FillStyle.FillMode = FillMode.Solid;
     ((SideBySideRangeBarSeriesView)pseries.View).Color = Color.FromArgb(242, 148, 65);
     ((SideBySideRangeBarSeriesView)pseries.View).FillStyle.FillMode = FillMode.Solid;
     ((SideBySideRangeBarSeriesView)sseries.View).Color = Color.FromArgb(206, 72, 34);
     ((SideBySideRangeBarSeriesView)sseries.View).FillStyle.FillMode = FillMode.Solid;
     if (fDS.Count > 0) fseries.DataSource = fDS;
     fseries.ArgumentScaleType = ScaleType.Numerical;
     fseries.ValueScaleType = ScaleType.Numerical;
     fseries.ValueDataMembers[0] = "startv";
     fseries.ValueDataMembers[1] = "endv";
     fseries.ArgumentDataMember = "id";
     rseries.ArgumentScaleType = ScaleType.Numerical;
     rseries.ValueScaleType = ScaleType.Numerical;
     rseries.ValueDataMembers[0] = "startv";
     rseries.ValueDataMembers[1] = "endv";
     rseries.ArgumentDataMember = "id";
     if (rDS.Count > 0) rseries.DataSource = rDS;
     pseries.ArgumentScaleType = ScaleType.Numerical;
     pseries.ValueScaleType = ScaleType.Numerical;
     pseries.ValueDataMembers[0] = "startv";
     pseries.ValueDataMembers[1] = "endv";
     pseries.ArgumentDataMember = "id";
     if (pDS.Count > 0) pseries.DataSource = pDS;
     sseries.ArgumentScaleType = ScaleType.Numerical;
     sseries.ValueScaleType = ScaleType.Numerical;
     sseries.ValueDataMembers[0] = "startv";
     sseries.ValueDataMembers[1] = "endv";
     sseries.ArgumentDataMember = "id";
     if (sDS.Count > 0) sseries.DataSource = sDS;
     wc.DataBind();
 }
开发者ID:alexkasp,项目名称:monitor,代码行数:72,代码来源:Comparer.aspx.cs


注:本文中的DevExpress.DataBind方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。