Esempio n. 1
0
        private void dgvAlmacenes_InitializeLayout(object sender, InitializeLayoutEventArgs e)
        {
            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];

            band.Columns[1].Hidden = true;

            band.Columns[0].Width = 80;
            band.Columns[1].Width = 40;
            band.Columns[2].Width = 80;
            band.Columns[3].Width = 90;
            band.Columns[4].Width = 90;
            band.Columns[5].Width = 90;
            band.Columns[6].Width = 90;
            band.Columns[7].Width = 90;

            band.Columns[3].Format = "C2";
            band.Columns[4].Format = "N2";
            band.Columns[5].Format = "N0";
            band.Columns[6].Format = "N0";
            band.Columns[7].Format = "N0";

            band.Columns[3].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns[4].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns[5].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns[6].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns[7].CellAppearance.TextHAlign = HAlign.Right;

            foreach (var item in band.Columns)
            {
                item.CellActivation = Activation.NoEdit;
            }
        }
Esempio n. 2
0
        private void dgvVentas_InitializeLayout(object sender, InitializeLayoutEventArgs e)
        {
            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];
            e.Layout.Override.SummaryDisplayArea          = Infragistics.Win.UltraWinGrid.SummaryDisplayAreas.BottomFixed;
            e.Layout.Override.SummaryFooterCaptionVisible = Infragistics.Win.DefaultableBoolean.False;
            e.Layout.Bands[0].Summaries.Clear();

            band.Columns["Num"].Hidden = true;

            band.Columns[3].Format = "C2";
            band.Columns[4].Format = "N0";

            band.Columns[3].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns[4].CellAppearance.TextHAlign = HAlign.Right;

            foreach (var item in band.Columns)
            {
                item.CellActivation = Activation.NoEdit;
                item.Width          = 110;
            }
            band.Columns["Año"].Width = 70;

            Infragistics.Win.UltraWinGrid.SummarySettings summary1 = band.Summaries.Add("T1", SummaryType.Sum, band.Columns[3]);
            summary1.DisplayFormat            = "{0:C1}";
            summary1.Appearance.TextHAlign    = Infragistics.Win.HAlign.Right;
            summary1.Appearance.BackColor     = Color.White;
            summary1.Appearance.FontData.Bold = DefaultableBoolean.True;

            Infragistics.Win.UltraWinGrid.SummarySettings summary2 = band.Summaries.Add("T2", SummaryType.Sum, band.Columns[4]);
            summary2.DisplayFormat            = "{0:N1}";
            summary2.Appearance.TextHAlign    = Infragistics.Win.HAlign.Right;
            summary2.Appearance.BackColor     = Color.White;
            summary2.Appearance.FontData.Bold = DefaultableBoolean.True;
        }
Esempio n. 3
0
        private void CreateLayout(IG.UltraGridLayout layout)
        {
            this.SuspendLayout();
            ((System.ComponentModel.ISupportInitialize)(this)).BeginInit();
            this.BeginUpdate();

            CreateGridLayout(this, layout, _CountX, _CountY);

            this.EndUpdate();
            ((System.ComponentModel.ISupportInitialize)(this)).EndInit();
            this.ResumeLayout(true);
        }
Esempio n. 4
0
        private void dgvAlmacenes_InitializeLayout(object sender, InitializeLayoutEventArgs e)
        {
            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];

            band.Columns["Línea"].Hidden   = true;
            band.Columns["WhsCode"].Hidden = true;

            foreach (var item in band.Columns)
            {
                item.CellActivation            = Activation.NoEdit;
                item.Width                     = 105;
                item.CellAppearance.TextHAlign = HAlign.Right;
                item.Format                    = "C0";
            }

            band.Columns[4].Format        = "N0";
            band.Columns["Almacén"].Width = 90;
            band.Columns["Almacén"].CellAppearance.TextHAlign = HAlign.Left;
        }
Esempio n. 5
0
        private void dgvDatos_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e)
        {
            foreach (UltraGridColumn item in e.Layout.Bands[0].Columns)
            {
                foreach (DataRow row in tblLines_Aux.Rows)
                {
                    if (item.Key.Equals(row["nameColumn"]))
                    {
                        item.Header.Caption = row.Field <string>("dscriptionColumn");
                        item.Width          = row.Field <int>("widthColumn");
                        if (row.Field <bool>("readonlyColumn" + _modeDocument))
                        {
                            item.CellActivation = Activation.NoEdit;
                        }
                        else
                        {
                            item.CellActivation = Activation.AllowEdit;
                        }

                        item.Hidden = !row.Field <bool>("visibleColumn");
                        item.Format = row.Field <string>("formatColumn");

                        if (row.Field <string>("alineacionColumn").Equals("left"))
                        {
                            item.CellAppearance.TextHAlign = HAlign.Left;
                        }
                        else if (row.Field <string>("alineacionColumn").Equals("rigth"))
                        {
                            item.CellAppearance.TextHAlign = HAlign.Right;
                        }
                        else if (row.Field <string>("alineacionColumn").Equals("center"))
                        {
                            item.CellAppearance.TextHAlign = HAlign.Center;
                        }

                        if (row.Field <bool>("listColumn"))
                        {
                            #region Crear List
                            using (SqlConnection connection = new SqlConnection(Datos.Clases.Constantes.conectionLog))
                            {
                                using (SqlCommand command = new SqlCommand("sp_SDKDataSource", connection))
                                {
                                    command.CommandType = CommandType.StoredProcedure;
                                    command.Parameters.AddWithValue("@TipoConsulta", row.Field <int>("TipoConsulta"));

                                    DataTable      tbl = new DataTable();
                                    SqlDataAdapter da  = new SqlDataAdapter();
                                    da.SelectCommand = command;
                                    da.Fill(tbl);

                                    if (row.Field <string>("nameColumn").Equals("ItemCode"))
                                    {
                                        item.ValueList = this.Form_Traspaso.ultraDropDown1;
                                    }
                                    else
                                    {
                                        ValueList vl;
                                        if (!e.Layout.ValueLists.Exists(row.Field <string>("nameColumn")))
                                        {
                                            vl = e.Layout.ValueLists.Add(row.Field <string>("nameColumn"));
                                            int num = 1;
                                            foreach (DataRow list in tbl.Rows)
                                            {
                                                vl.ValueListItems.Add(num, list.Field <string>("code") + " | " + list.Field <string>("name"));
                                                num++;
                                            }
                                        }
                                        item.ValueList = e.Layout.ValueLists[row.Field <string>("nameColumn")];
                                    }
                                }
                            }

                            #endregion
                        }
                    }
                }
            }

            #region suma LineTotal, Volumen, Peso
            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];

            e.Layout.Override.SummaryDisplayArea          = Infragistics.Win.UltraWinGrid.SummaryDisplayAreas.BottomFixed;
            e.Layout.Override.SummaryFooterCaptionVisible = Infragistics.Win.DefaultableBoolean.False;
            e.Layout.Bands[0].Summaries.Clear();

            Infragistics.Win.UltraWinGrid.SummarySettings summary3 = band.Summaries.Add("VOL", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns["Volumen"]);
            Infragistics.Win.UltraWinGrid.SummarySettings summary2 = band.Summaries.Add("PESO", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns["Peso"]);
            //Infragistics.Win.UltraWinGrid.SummarySettings summary1 = band.Summaries.Add("Total", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns["LineTotal"]);

            summary2.DisplayFormat         = "{0:N1} Kg";
            summary2.Appearance.TextHAlign = HAlign.Right;
            //summary2.Appearance.FontData.Bold = DefaultableBoolean.True;

            summary3.DisplayFormat         = "{0:N1} ft3";
            summary3.Appearance.TextHAlign = HAlign.Right;
            //summary3.Appearance.FontData.Bold = DefaultableBoolean.True;

            //summary1.Appearance.BackColor = Color.White;
            //summary1.Appearance.ForeColor = Color.White;
            #endregion
        }
Esempio n. 6
0
        private void dgvDatos_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e)
        {
            Infragistics.Win.UltraWinCalcManager.UltraCalcManager calcManager;
            calcManager = new Infragistics.Win.UltraWinCalcManager.UltraCalcManager(this.Container);
            e.Layout.Grid.CalcManager = calcManager;

            foreach (Infragistics.Win.UltraWinGrid.UltraGridColumn item in e.Layout.Bands[0].Columns)
            {
                item.Format                    = "N0";
                item.Width                     = 90;
                item.CellActivation            = Infragistics.Win.UltraWinGrid.Activation.NoEdit;
                item.CellAppearance.TextHAlign = Infragistics.Win.HAlign.Right;
            }

            e.Layout.Bands[0].Columns[(int)Columnas.Articulo].CellAppearance.TextHAlign    = Infragistics.Win.HAlign.Left;
            e.Layout.Bands[0].Columns[(int)Columnas.Descripcion].CellAppearance.TextHAlign = Infragistics.Win.HAlign.Left;

            e.Layout.Bands[0].Columns[(int)Columnas.Descripcion].Width = 180;
            //e.Layout.Bands[0].Columns[(int)Columnas.Cantidad].Header.Caption = "Cantidad en OC";

            e.Layout.Bands[0].Columns[(int)Columnas.CantidadZNORTE].Header.Caption = "Transferir a MTY";
            e.Layout.Bands[0].Columns[(int)Columnas.CantidadGDL].Header.Caption    = "Transferir a PUE";
            e.Layout.Bands[0].Columns[(int)Columnas.CEDIS].Header.Caption          = "Transferir a CEDIS";
            e.Layout.Bands[0].Columns[(int)Columnas.CantidadMEX].Header.Caption    = "Transferir a EDOMEX";

            e.Layout.Bands[0].Columns[(int)Columnas.StockGDL].Hidden    = true;
            e.Layout.Bands[0].Columns[(int)Columnas.StockMEX].Hidden    = true;
            e.Layout.Bands[0].Columns[(int)Columnas.StockZNORTE].Hidden = true;

            e.Layout.Bands[0].Columns[(int)Columnas.IdealGDL].Hidden    = true;
            e.Layout.Bands[0].Columns[(int)Columnas.IdealZNORTE].Hidden = true;
            e.Layout.Bands[0].Columns[(int)Columnas.IdealMEX].Hidden    = true;


            //e.Layout.Bands[0].Columns[(int)Columnas.PZNORTE].Header.Caption = "%";
            //e.Layout.Bands[0].Columns[(int)Columnas.PGDL].Header.Caption = "%";

            //e.Layout.Bands[0].Columns[(int)Columnas.PZNORTE].Format = "P2";
            //e.Layout.Bands[0].Columns[(int)Columnas.PGDL].Format = "P2";

            //e.Layout.Bands[0].Columns[(int)Columnas.PZNORTE].Width = 70;
            //e.Layout.Bands[0].Columns[(int)Columnas.PGDL].Width = 70;

            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];

            e.Layout.Override.SummaryDisplayArea          = Infragistics.Win.UltraWinGrid.SummaryDisplayAreas.TopFixed;// SummaryDisplayAreas.Top;
            e.Layout.Override.SummaryFooterCaptionVisible = Infragistics.Win.DefaultableBoolean.False;
            e.Layout.Bands[0].Summaries.Clear();

            Infragistics.Win.UltraWinGrid.SummarySettings summary1 = band.Summaries.Add("GDL", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns[(int)Columnas.CantidadGDL]);
            Infragistics.Win.UltraWinGrid.SummarySettings summary2 = band.Summaries.Add("CEDIS", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns[(int)Columnas.CEDIS]);
            Infragistics.Win.UltraWinGrid.SummarySettings summary3 = band.Summaries.Add("Total", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns[(int)Columnas.Cantidad]);
            Infragistics.Win.UltraWinGrid.SummarySettings summary4 = band.Summaries.Add("ZNORTE", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns[(int)Columnas.CantidadZNORTE]);
            Infragistics.Win.UltraWinGrid.SummarySettings summary5 = band.Summaries.Add("MEX", Infragistics.Win.UltraWinGrid.SummaryType.Sum, band.Columns[(int)Columnas.CantidadMEX]);

            //Infragistics.Win.UltraWinGrid.SummarySettings summary5 = band.Summaries.Add("p1", Infragistics.Win.UltraWinGrid.SummaryType.Formula, band.Columns[(int)Columnas.PZNORTE]);
            //Infragistics.Win.UltraWinGrid.SummarySettings summary6 = band.Summaries.Add("p2", Infragistics.Win.UltraWinGrid.SummaryType.Formula, band.Columns[(int)Columnas.PGDL]);


            //summary5.Formula = "SUM([CantidadMTY])/SUM([Cantidad])";
            //summary6.Formula = "SUM([CantidadPUE])/SUM([Cantidad])";

            summary1.DisplayFormat = "{0:N0}";
            summary2.DisplayFormat = "{0:N0}";
            summary3.DisplayFormat = "{0:N0}";
            summary4.DisplayFormat = "{0:N0}";
            summary5.DisplayFormat = "{0:N0}";
            //summary6.DisplayFormat = "{0:P2}";

            summary1.Appearance.FontData.Bold = DefaultableBoolean.True;
            summary2.Appearance.FontData.Bold = DefaultableBoolean.True;
            summary3.Appearance.FontData.Bold = DefaultableBoolean.True;
            summary4.Appearance.FontData.Bold = DefaultableBoolean.True;
            summary5.Appearance.FontData.Bold = DefaultableBoolean.True;
            //summary6.Appearance.FontData.Bold = DefaultableBoolean.True;

            summary1.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;
            summary2.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;
            summary3.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;
            summary4.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;
            summary5.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;
            //summary6.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            //e.Layout.Bands[0].Columns[(int)Columnas.IdealGDL].Hidden = Aduana.Equals("manzanillo");
            //e.Layout.Bands[0].Columns[(int)Columnas.StockGDL].Hidden = Aduana.Equals("manzanillo");
            //e.Layout.Bands[0].Columns[(int)Columnas.CantidadGDL].Hidden = Aduana.Equals("manzanillo");
            //e.Layout.Bands[0].Columns[(int)Columnas.PGDL].Hidden = Aduana.Equals("manzanillo");

            //e.Layout.Bands[0].Columns[(int)Columnas.IdealZCENTRO].Hidden = Aduana.Equals("manzanillo");
            //e.Layout.Bands[0].Columns[(int)Columnas.StockZCENTRO].Hidden = Aduana.Equals("manzanillo");
        }
Esempio n. 7
0
        private static IG.UltraGridLayout CreateGridLayout(IG.UltraGrid grid, IG.UltraGridLayout layout, int countX, int countY)
        {
            if (layout == null)
            {
                layout = grid.DisplayLayout.Clone();
            }
            layout.Key = "FreeFormLayout";
            layout.Grid?.BeginUpdate();

            IG.UltraGridBand gridBand = layout?.Bands[0] ?? grid.Rows.Band;

            ActivateFreeForm(grid, gridBand);

            #region Souřadnice a velikosti

            int maxR = 0;
            int maxB = 0;

            int itemX0 = 6;
            int itemY0 = 6;
            int itemXS = 3;
            int itemYS = 3;
            int itemW  = 220;
            int itemH  = 25;
            int itemX  = itemX0;
            int itemY  = itemY0;

            int     labelW    = 100;
            int     labelH    = 18;
            DW.Size labelSize = new DW.Size(labelW, labelH);

            int     textW    = 110;
            int     textH    = 22;
            DW.Size textSize = new DW.Size(textW, textH);
            #endregion

            int tabIndex = 0;
            for (int rowIdx = 0; rowIdx < countY; rowIdx++)
            {
                itemX = itemX0;
                for (int colIdx = 0; colIdx < countX; colIdx++)
                {
                    DW.Rectangle itemBounds = new DW.Rectangle(itemX, itemY, itemW, itemH);

                    string             columnName = CreateColumnName(rowIdx, colIdx);
                    IG.UltraGridColumn column     = gridBand.Columns[columnName];
                    column.TabIndex = ++tabIndex;

                    var colLayout = column.RowLayoutColumnInfo;
                    colLayout.OriginX           = itemBounds.X;
                    colLayout.OriginY           = itemBounds.Y;
                    colLayout.SpanX             = textSize.Width;
                    colLayout.SpanY             = textSize.Height;
                    colLayout.PreferredCellSize = textSize; //  itemBounds.Size;

                    colLayout.LabelPosition      = IG.LabelPosition.Left;
                    colLayout.PreferredLabelSize = labelSize;
                    colLayout.ActualLabelSize    = labelSize;
                    colLayout.LabelSpan          = labelW;

                    if (maxR < itemBounds.Right)
                    {
                        maxR = itemBounds.Right;
                    }
                    if (maxB < itemBounds.Bottom)
                    {
                        maxB = itemBounds.Bottom;
                    }

                    itemX = itemX + itemW + itemXS;
                }
                itemY = itemY + itemH + itemYS;
            }

            grid.Size = new DW.Size(maxR + itemX0, maxB + itemY0);

            layout.ViewStyle = Infragistics.Win.UltraWinGrid.ViewStyle.SingleBand;
            layout.Grid?.EndUpdate();

            if (layout.Rows.Count > 0)
            {
                grid.ActiveRow = layout.Rows[0];
            }

            return(layout);
        }
Esempio n. 8
0
        private void dgvDatos_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e)
        {
            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];
            e.Layout.Override.SummaryDisplayArea          = Infragistics.Win.UltraWinGrid.SummaryDisplayAreas.BottomFixed;
            e.Layout.Override.SummaryFooterCaptionVisible = Infragistics.Win.DefaultableBoolean.False;
            e.Layout.Bands[0].Summaries.Clear();

            band.Columns["coment"].Header.Caption = "--";
            band.Columns["coment"].Width          = 25;
            //band.Columns["RT"].Header.Caption = string.Empty;
            //band.Columns["DT"].Header.Caption = string.Empty;
            //band.Columns["CPT"].Header.Caption = string.Empty;
            //band.Columns["PPCT"].Header.Caption = string.Empty;

            //band.Columns["ANT"].Width = 1;
            //band.Columns["RT"].Width = 1;
            //band.Columns["DT"].Width = 1;
            //band.Columns["CPT"].Width = 1;
            //band.Columns["PPCT"].Width = 1;

            band.Columns["Solicitado ($)"].Hidden = true;
            band.Columns["C"].Hidden = true;


            band.Columns["Proveedor"].Width      = 90;
            band.Columns["Artículo"].Width       = 80;
            band.Columns["ABC"].Width            = 50;
            band.Columns["Stock"].Width          = 80;
            band.Columns["Ideal"].Width          = 80;
            band.Columns["Diferencia"].Width     = 80;
            band.Columns["Solicitado"].Width     = 80;
            band.Columns["Stock ($)"].Width      = 80;
            band.Columns["Ideal ($)"].Width      = 80;
            band.Columns["Diferencia ($)"].Width = 80;
            band.Columns["Solicitado ($)"].Width = 80;
            band.Columns["Veces ideal"].Width    = 70;
            band.Columns["Días stock"].Width     = 70;
            band.Columns["Accion"].Width         = 70;
            band.Columns["Comentarios"].Width    = 70;

            band.Columns["Accion"].ValueList = udpAcciones;

            band.Columns["Stock"].CellAppearance.TextHAlign          = HAlign.Right;
            band.Columns["Ideal"].CellAppearance.TextHAlign          = HAlign.Right;
            band.Columns["Diferencia"].CellAppearance.TextHAlign     = HAlign.Right;
            band.Columns["Solicitado"].CellAppearance.TextHAlign     = HAlign.Right;
            band.Columns["Stock ($)"].CellAppearance.TextHAlign      = HAlign.Right;
            band.Columns["Ideal ($)"].CellAppearance.TextHAlign      = HAlign.Right;
            band.Columns["Diferencia ($)"].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns["Solicitado ($)"].CellAppearance.TextHAlign = HAlign.Right;
            band.Columns["Veces ideal"].CellAppearance.TextHAlign    = HAlign.Right;
            band.Columns["Días stock"].CellAppearance.TextHAlign     = HAlign.Right;
            band.Columns["%"].CellAppearance.TextHAlign = HAlign.Right;

            band.Columns["Stock"].Format          = "N0";
            band.Columns["Ideal"].Format          = "N0";
            band.Columns["Diferencia"].Format     = "N0";
            band.Columns["Solicitado"].Format     = "N0";
            band.Columns["Stock ($)"].Format      = "C2";
            band.Columns["Ideal ($)"].Format      = "C2";
            band.Columns["Diferencia ($)"].Format = "C2";
            band.Columns["Solicitado ($)"].Format = "C2";
            band.Columns["Veces ideal"].Format    = "N2";
            band.Columns["Días stock"].Format     = "N2";
            band.Columns["%"].Format = "P2";

            band.Columns["Proveedor"].Header.Fixed = true;
            band.Columns["Artículo"].Header.Fixed  = true;
            band.Columns["ABC"].Header.Fixed       = true;

            Infragistics.Win.UltraWinGrid.SummarySettings summary1 = band.Summaries.Add("T1", SummaryType.Sum, band.Columns["Diferencia ($)"]);
            summary1.DisplayFormat         = "{0:C1}";
            summary1.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary2 = band.Summaries.Add("T2", SummaryType.Sum, band.Columns["Stock ($)"]);
            summary2.DisplayFormat         = "{0:C1}";
            summary2.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary3 = band.Summaries.Add("T3", SummaryType.Sum, band.Columns["Ideal ($)"]);
            summary3.DisplayFormat         = "{0:C1}";
            summary3.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            foreach (var item in band.Columns)
            {
                item.CellActivation = Activation.NoEdit;
            }

            band.Columns["Accion"].CellActivation = Activation.AllowEdit;
            //e.Layout.Bands[0].Columns["Accion"].ValueList = udpAcciones;
        }
Esempio n. 9
0
        private void dgvDatos_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e)
        {
            Infragistics.Win.UltraWinGrid.UltraGridLayout layout = e.Layout;
            Infragistics.Win.UltraWinGrid.UltraGridBand   band   = layout.Bands[0];
            e.Layout.Override.SummaryDisplayArea          = Infragistics.Win.UltraWinGrid.SummaryDisplayAreas.BottomFixed;
            e.Layout.Override.SummaryFooterCaptionVisible = Infragistics.Win.DefaultableBoolean.False;
            e.Layout.Bands[0].Summaries.Clear();

            band.Columns["ItmsGrpNam"].Header.Caption = "Línea";

            band.Columns["Stock"].CellAppearance.TextHAlign            = HAlign.Right;
            band.Columns["Ideal"].CellAppearance.TextHAlign            = HAlign.Right;
            band.Columns["Diferencia"].CellAppearance.TextHAlign       = HAlign.Right;
            band.Columns["Solicitado"].CellAppearance.TextHAlign       = HAlign.Right;
            band.Columns["A"].CellAppearance.TextHAlign                = HAlign.Right;
            band.Columns["B"].CellAppearance.TextHAlign                = HAlign.Right;
            band.Columns["C"].CellAppearance.TextHAlign                = HAlign.Right;
            band.Columns["Remate"].CellAppearance.TextHAlign           = HAlign.Right;
            band.Columns["Obsoleto"].CellAppearance.TextHAlign         = HAlign.Right;
            band.Columns["Artículos nuevos"].CellAppearance.TextHAlign = HAlign.Right;


            band.Columns["Stock"].Format            = "C0";
            band.Columns["Ideal"].Format            = "C0";
            band.Columns["Diferencia"].Format       = "C0";
            band.Columns["Solicitado"].Format       = "C0";
            band.Columns["A"].Format                = "C0";
            band.Columns["B"].Format                = "C0";
            band.Columns["C"].Format                = "C0";
            band.Columns["Remate"].Format           = "C0";
            band.Columns["Obsoleto"].Format         = "C0";
            band.Columns["Artículos nuevos"].Format = "C0";

            band.Columns["ItmsGrpNam"].Header.Fixed = true;

            Infragistics.Win.UltraWinGrid.SummarySettings summary1 = band.Summaries.Add("T1", SummaryType.Sum, band.Columns["Diferencia"]);
            summary1.DisplayFormat         = "{0:C1}";
            summary1.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary2 = band.Summaries.Add("T2", SummaryType.Sum, band.Columns["Stock"]);
            summary2.DisplayFormat         = "{0:C1}";
            summary2.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary3 = band.Summaries.Add("T3", SummaryType.Sum, band.Columns["Ideal"]);
            summary3.DisplayFormat         = "{0:C1}";
            summary3.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary4 = band.Summaries.Add("T4", SummaryType.Sum, band.Columns["Solicitado"]);
            summary4.DisplayFormat         = "{0:C1}";
            summary4.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary5 = band.Summaries.Add("T5", SummaryType.Sum, band.Columns["A"]);
            summary5.DisplayFormat         = "{0:C1}";
            summary5.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary6 = band.Summaries.Add("T6", SummaryType.Sum, band.Columns["B"]);
            summary6.DisplayFormat         = "{0:C1}";
            summary6.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary7 = band.Summaries.Add("T7", SummaryType.Sum, band.Columns["C"]);
            summary7.DisplayFormat         = "{0:C1}";
            summary7.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary8 = band.Summaries.Add("T8", SummaryType.Sum, band.Columns["Remate"]);
            summary8.DisplayFormat         = "{0:C1}";
            summary8.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary9 = band.Summaries.Add("T9", SummaryType.Sum, band.Columns["Obsoleto"]);
            summary9.DisplayFormat         = "{0:C1}";
            summary9.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            Infragistics.Win.UltraWinGrid.SummarySettings summary10 = band.Summaries.Add("T10", SummaryType.Sum, band.Columns["Artículos nuevos"]);
            summary10.DisplayFormat         = "{0:C1}";
            summary10.Appearance.TextHAlign = Infragistics.Win.HAlign.Right;

            foreach (var item in band.Columns)
            {
                item.CellActivation = Activation.NoEdit;
                item.Width          = 110;
            }

            band.Columns["ItmsGrpNam"].Width = 95;
        }