예제 #1
0
        private void btnReport_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            grdFlat.DataSource = ProjReceivableBL.Get_Flat_ReceivableReport(m_iProjectId, dtAson);
            grdFlatView.PopulateColumns();
            grdFlatView.Columns["CostCentreId"].Visible = false;
            grdFlatView.Columns["FlatId"].Visible       = false;
            grdFlatView.Columns["BlockId"].Visible      = false;
            grdFlatView.Columns["BlockName"].Visible    = false;
            FillFlatGridReport();

            grdFlatView.Columns["BlockName"].Group();
            PrintableComponentLink Link = new PrintableComponentLink(new PrintingSystem());

            Link.Landscape = true;
            Link.Component = grdFlat;
            Link.CreateMarginalHeaderArea += Link4_CreateMarginalHeaderArea;
            Link.CreateMarginalFooterArea += Link_CreateMarginalFooterArea;
            Link.CreateDocument();
            Link.ShowPreview();

            grdFlatView.Columns["BlockName"].UnGroup();
            grdFlat.DataSource = ProjReceivableBL.Get_Flat_Receivable(m_iProjectId, m_iBlockId, dtAson);
            grdFlatView.PopulateColumns();
            grdFlatView.Columns["FlatId"].Visible = false;
            FillFlatGrid();
            //grdFlatView.Columns["BlockName"].Visible = false;
        }
예제 #2
0
        public void Fill_Flat_Receivable()
        {
            if (grdBlockView.FocusedRowHandle >= 0)
            {
                m_sBlockName = grdBlockView.GetFocusedRowCellValue("BlockName").ToString();

                grdFlat.DataSource = ProjReceivableBL.Get_Flat_Receivable(m_iProjectId, m_iBlockId, dtAson);
                grdFlatView.PopulateColumns();
                grdFlat.ForceInitialize();

                FillFlatGrid();
            }
        }