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


C# GridColumn.GetFilterStyle方法代码示例

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


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

示例1: FilterDateTimePicker

        /// <summary>
        /// FilterDateTimePicker
        /// </summary>
        /// <param name="gridColumn"></param>
        public FilterDateTimePicker(GridColumn gridColumn)
        {
            InitializeComponent();

            SuperGridControl sg = gridColumn.SuperGrid;

            LoadLocalizedStrings(sg);

            cbxShowAll.Text = sg.FilterShowAllString;
            cbxShowNull.Text = sg.FilterShowNullString;
            cbxShowNotNull.Text = sg.FilterShowNotNullString;

            if (string.IsNullOrEmpty(cbxShowNull.Text) == true)
                cbxShowNull.Visible = false;

            if (string.IsNullOrEmpty(cbxShowNotNull.Text) == true)
                cbxShowNotNull.Visible = false;

            if (cbxShowNull.Visible == false || cbxShowNotNull.Visible == false)
            {
                int y = (cbxDateRelative.Location.Y - cbxShowAll.Size.Height) / 2;

                cbxShowAll.Location = new Point(cbxShowAll.Location.X, y);

                if (cbxShowNull.Visible == true)
                    cbxShowNull.Location = new Point(cbxShowNull.Location.X, y);

                if (cbxShowNotNull.Visible == true)
                    cbxShowNotNull.Location = new Point(cbxShowNotNull.Location.X, y);
            }

            btnApply.Text = sg.FilterApplyString;

            if (sg.FilterCustomString != null)
            {
                cbxCustom.Text = sg.FilterCustomString;
                btnCustom.Text = sg.FilterCustomString + "...";
            }
            else
            {
                cbxCustom.Visible = false;
                btnCustom.Visible = false;
            }

            cbxDateRelative.Text = _filterByRelativeDateString;
            cbxDateSpecific.Text = _filterBySpecificDateString;
            cbxDateRange.Text = _filterByDateRangeString;

            cboDateRelative.Items.Add(CurrentMonth);
            cboDateRelative.Items.Add(CurrentYear);
            cboDateRelative.Items.Add(LastMonthPeriod);
            cboDateRelative.Items.Add(Last3MonthPeriod);
            cboDateRelative.Items.Add(Last6MonthPeriod);
            cboDateRelative.Items.Add(Last9MonthPeriod);
            cboDateRelative.Items.Add(LastYear);
            cboDateRelative.Items.Add(Last5YearPeriod);
            cboDateRelative.Items.Add(Last10YearPeriod);

            cboDateRelative.SelectedIndex = 0;

            _GridColumn = gridColumn;

            FilterColumnHeaderVisualStyle style = _GridColumn.GetFilterStyle(StyleType.Default);

            Font = style.Font;
            BackColor = style.Background.Color1;

            Cancel = false;
        }
开发者ID:huamanhtuyen,项目名称:VNACCS,代码行数:73,代码来源:FilterDateTimePicker.cs


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