DevExpresss XtraGrid Footer CustomDraw

Published Sep 12, 2012 | Updated Sep 28, 2022 | 0 comments

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;
        }
    }
}

TAG INFORMATION

Learn more on this topic

Related Blog Posts

윈도우 폼 개발후 배포시 사이즈가 이상하다…?

AutoScaleMode열거형 Windows Forms에서 지원하는 여러 종류의 자동 크기 조정 모드를 지정합니다. 네임스페이스: System.Windows.Forms 어셈블리: System.Windows.Forms(System.Windows.Forms.dll) 구문 public enum AutoScaleMode 멤버 이름 설명 None 자동 크기조정을 사용할 수 없습니다. Font 클래스에서 사용하는글꼴(대개 시스템 글꼴)의 크기를 기준으로 크기를 제어합니다. Dpi...

read more
asp.net development server port issue

asp.net development server port issue

지금껏 C/S 만 위주로 개발을 하다 오랜만에 Web 관련 프로젝트를 하고있다.. 물론 Silverlight 라서 크게 문제되지는 않지만 8, 9 년 전에 PHP 하던게 Web 관련 일은 전부인지라... 이것 저것 걸리는게 많다... 그 와중에 간간히.. 때때로 매번.... Silverlight 쪽 소스 변경한 것을 확인할려고 솔루션 탐색기의 Web Project 를 디버그 모드로 실행하면("마우스 우클릭=>디버그=>새 인스턴스 시작") 위와 같은 에러가 난다......

read more

c# thread safe extension method

public static class ExtensionMethod { public static TResult SafeInvoke(this T isi, Func call) where T : ISynchronizeInvoke { if(isi.InvokeRequired) { IAsyncResult result = isi.BeginInvoke(call, new object[] { isi }); object endResult = isi.EndInvoke(result); return...

read more

Join in the conversation

Leave a Comment

0 Comments

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

무료 온라인 전광판

전광판

텍스트를 입력하고 텍스트 효과 및 배경효과 를 변경해서 전체화면으로 표시할 수 있는 전광판 용도로 사용하실 수 있습니다. 각종 스포츠 및 공연 관람시 응원 용도로 사용이 가능합니다.

Carousel

여러개의 슬라이드를 추가하여 프레젠테이션 및 이미지 슬라이드 용도로 사용하실 수 있습니다. 브라우저가 포함된 IT 기기로 큰 모니터에 연결하여 매장 내 공지사항 및 메뉴소개를 이미지로 표시할 수 있습니다.

Pin It on Pinterest

Shares
Share This

Share This

Share this post with your friends!

Shares