using DevExpress.Utils;
using DevExpress.XtraGrid.Views.Grid;
using System.Drawing;
private void gvMain_CustomDrawFooterCell(object sender, FooterCellCustomDrawEventArgs e)
{
if (GridData == null)
{
return;
}
if (e.Column == colRepQtyName)
{
e.Info.DisplayText = _projectCumulativePlan;
e.Info.Bounds = new Rectangle(e.Bounds.X, e.Bounds.Y, this.bandMain.Width, e.Bounds.Height);
e.Info.Appearance.Options.UseTextOptions = true;
e.Info.Appearance.TextOptions.HAlignment = HorzAlignment.Center;
e.Painter.DrawObject(e.Info);
e.Handled = true;
}
else
{
string fieldName = e.Column.FieldName;
if (fieldName.StartsWith(CpjUtil.C_MonthColumnFieldNamePrefix))
{
string value = string.Format(e.Column.SummaryItem.DisplayFormat
, _sortedValueWithAccum[fieldName.Split('_')[1].CPJToDateTime()].AccumValue);
e.Info.DisplayText = value;
e.Painter.DrawObject(e.Info);
e.Handled = true;
}
}
}
FarPoint Spread 데이터와 헤더라벨을 고려한 컬럼너비 자동조정
/// <summary> /// 스프레드 컬럼별 너비를 자동조절(헤더 라벨 고려) /// 2010-11-12 By KKOMZI : Multi Row Header 고려 /// </summary> /// <param name="fpSheet"></param> /// <param name="pExtWidth">추가로 확장시킬 너비</param> public static void SetResizeColALL(SheetView fpSheet, int...
0 Comments