コード例 #1
0
 /// <summary>
 /// 컬럼(Cell) 텍스트 정렬. Default 는 가로, 세로 정렬 Center
 /// </summary>
 /// <param name="gvCurrentView"></param>
 /// <param name="iColumnIndex"></param>
 /// <param name="HAlignment"></param>
 /// <param name="VAlignment"></param>
 public static void SetCellAlignmentGridView(GridView gvCurrentView, int iColumnIndex
                                             , DevExpress.Utils.HorzAlignment HAlignment = HorzAlignment.Center, DevExpress.Utils.VertAlignment VAlignment = VertAlignment.Center)
 {
     gvCurrentView.Columns[iColumnIndex].AppearanceCell.TextOptions.HAlignment = HAlignment;
     gvCurrentView.Columns[iColumnIndex].AppearanceCell.TextOptions.VAlignment = VAlignment;
 }
コード例 #2
0
 /// <summary>
 /// 헤더 컬럼 텍스트 정렬. Default 는 가로, 세로 정렬 Center
 /// </summary>
 /// <param name="_gridView"></param>
 /// <param name="iColumnIndex"></param>
 /// <param name="HAlignment"></param>
 /// <param name="VAlignment"></param>
 public static void SetHeaderAlignmentGridView(this GridView _gridView, int iColumnIndex, DevExpress.Utils.HorzAlignment HAlignment = HorzAlignment.Center, DevExpress.Utils.VertAlignment VAlignment = VertAlignment.Center)
 {
     _gridView.Columns[iColumnIndex].AppearanceHeader.TextOptions.HAlignment = HAlignment;
     _gridView.Columns[iColumnIndex].AppearanceHeader.TextOptions.VAlignment = VAlignment;
 }