zoukankan      html  css  js  c++  java
  • c# dev SearchLookUpEdit 控件自定义列和自增序号

    效果图:

    自定义显示列:

     

    DataBinder.BindingSearchLookupEditDataSource(txtFProductCode, ProductDt, "FItemID", "FItemID",800,700); //控件名,数据源,列名,列明,长,宽

    设置窗体中的自增序号

    1.定义自增序号

            private void searchLookUpEdit1View_CustomDrawRowIndicator(object sender, RowIndicatorCustomDrawEventArgs e)
            {
                //设置窗体中的自增序号
                if (e.Info.IsRowIndicator && e.RowHandle >= 0)
                {
                    e.Info.DisplayText = (e.RowHandle + 1).ToString();
                }
            }

    2.添加到引用

     在searchLookUpEdit1View中添加下面这一句的引用即可

    this.searchLookUpEdit1View.CustomDrawRowIndicator += new DevExpress.XtraGrid.Views.Grid.RowIndicatorCustomDrawEventHandler(this.searchLookUpEdit1View_CustomDrawRowIndicator);

  • 相关阅读:
    hdu4726
    hdu2709
    hdu4706
    hdu4715
    快速幂取模
    快速幂
    asp.net中页面传值
    微信小程序支付
    sql 查询重复记录值取一条
    bower使用
  • 原文地址:https://www.cnblogs.com/damugua/p/14655764.html
Copyright © 2011-2022 走看看