SetBorder() public méthode

Set a table border Added by lckuiper @ 20101117
public SetBorder ( TableBorderType borderType, Novacode.Border border ) : void
borderType TableBorderType The table border to set
border Novacode.Border Border object to set the table border
Résultat void
        private static void TablazatFormazas( Table table ) {
            table.AutoFit = AutoFit.Contents;
            table.AutoFit = AutoFit.ColumnWidth;
            foreach( Row row in table.Rows ) {
                row.Cells[0].Width = 30;
                row.Cells[1].Width = 50;
                row.Cells[2].Width = 50;
                row.Cells[3].Width = 200;
                row.Cells[4].Width = 200;
                row.Cells[5].Width = 70;
                row.Cells[6].Width = 70;
            }

            Border c = new Border(Novacode.BorderStyle.Tcbs_none, BorderSize.seven, 0, Color.Black);
            Border d = new Border(Novacode.BorderStyle.Tcbs_single, BorderSize.five, 0, Color.Black);
            table.SetBorder( TableBorderType.InsideH, d );
            table.SetBorder( TableBorderType.InsideV, c );
            table.SetBorder( TableBorderType.Bottom, c );
            table.SetBorder( TableBorderType.Top, c );
            table.SetBorder( TableBorderType.Left, c );
            table.SetBorder( TableBorderType.Right, c );

        }
        private void AdatTablazatFormazas( Table table ) {
            Border b = new Border(Novacode.BorderStyle.Tcbs_none, BorderSize.seven, 0, Color.Blue);
            Border c = new Border(Novacode.BorderStyle.Tcbs_single, BorderSize.seven, 0, Color.Black);

            table.SetBorder( TableBorderType.InsideH, b );
            table.SetBorder( TableBorderType.InsideV, b );
            table.SetBorder( TableBorderType.Bottom, b );
            table.SetBorder( TableBorderType.Top, b );
            table.SetBorder( TableBorderType.Left, b );
            table.SetBorder( TableBorderType.Right, b );

            for( int i = 0; i < 4; i++ ) {
                table.Rows[0].Cells[i].SetBorder( TableCellBorderType.Bottom, c );
            }

            table.AutoFit = AutoFit.ColumnWidth;
            foreach( Row row in table.Rows ) {
                row.Cells[0].Width = 100;
                row.Cells[1].Width = 250;
                row.Cells[2].Width = 250;
                row.Cells[3].Width = 100;
            }

            foreach( Row row in table.Rows ) {
                row.Height = 20;
            }
        }
Exemple #3
0
        KonszignacioFejlecTablazatFormazas( Table _table )
        {
            Border c = new Border( BorderStyle.Tcbs_none, BorderSize.seven, 0, Color.Black );
            _table.SetBorder( TableBorderType.InsideH, c );
            _table.SetBorder( TableBorderType.InsideV, c );
            _table.SetBorder( TableBorderType.Bottom, c );
            _table.SetBorder( TableBorderType.Top, c );
            _table.SetBorder( TableBorderType.Left, c );
            _table.SetBorder( TableBorderType.Right, c );

            //konszig táblázat fejléc-BN
            _table.AutoFit = AutoFit.ColumnWidth;

            for ( int i = 0 ; i < _table.Rows.Count ; i++ )
            {
                _table.Rows[ i ].Cells[ 0 ].Width = 80;         //vevő fix
                _table.Rows[ i ].Cells[ 1 ].Width = 300;        //vevő
                _table.Rows[ i ].Cells[ 2 ].Width = 60;         //feladó fix
                _table.Rows[ i ].Cells[ 3 ].Width = 300;        //feladó
            }
            _table.AutoFit = AutoFit.ColumnWidth;
        }
Exemple #4
0
        KonszignacioDataTableFormazas( Table _table )
        {
            _table.AutoFit = AutoFit.Contents;
            Border c = new Border( BorderStyle.Tcbs_none, BorderSize.two, 0, Color.Black );
            _table.SetBorder( TableBorderType.InsideH, c );
            _table.SetBorder( TableBorderType.InsideV, c );
            _table.SetBorder( TableBorderType.Bottom, c );
            _table.SetBorder( TableBorderType.Top, c );
            _table.SetBorder( TableBorderType.Left, c );
            _table.SetBorder( TableBorderType.Right, c );

            for ( int i = 0 ; i < _table.Rows[ 0 ].Cells.Count ; i++ )
            {
                _table.Rows[ 0 ].Cells[ i ].SetBorder( TableCellBorderType.Top, new Border( BorderStyle.Tcbs_single, BorderSize.six, 0, Color.Black ) );
                _table.Rows[ 0 ].Cells[ i ].SetBorder( TableCellBorderType.Bottom, new Border( BorderStyle.Tcbs_single, BorderSize.six, 0, Color.Black ) );
            }
            for ( int i = 0 ; i < _table.Rows.Count ; i++ )
            {
                if ( _table.Rows[ i ].Cells[ 1 ].Paragraphs[ 0 ].Text.Contains( "összesen" ) )
                {
                    for ( int j = 0 ;
                         j < _table.Rows[ i ].Cells.Count ;
                         j++ )
                    {
                        _table.Rows[ i ].Cells[ j ].SetBorder( TableCellBorderType.Top, new Border( BorderStyle.Tcbs_single,
                                                                                       BorderSize.six, 0, Color.Black ) );
                    }
                }
                else if ( _table.Rows[ i ].Cells[ 1 ].Paragraphs[ 0 ].Text.Contains( "elszállítás" ) )
                {
                    for ( int j = 0 ;
                         j < _table.Rows[ i ].Cells.Count ;
                         j++ )
                    {
                        _table.Rows[ i ].Cells[ j ].SetBorder( TableCellBorderType.Top, new Border( BorderStyle.Tcbs_single,
                                                                                               BorderSize.six, 0, Color.Black ) );
                        _table.Rows[ i ].Cells[ j ].SetBorder( TableCellBorderType.Bottom, new Border( BorderStyle.Tcbs_single,
                                                                                                BorderSize.six, 0, Color.Black ) );
                    }
                    _table.Rows[ i ].Cells[ 0 ].SetBorder( TableCellBorderType.Left, new Border( BorderStyle.Tcbs_single,
                                                                                            BorderSize.six, 0, Color.Black ) );
                    _table.Rows[ i ].Cells[ 6 ].SetBorder( TableCellBorderType.Right, new Border( BorderStyle.Tcbs_single,
                                                                                            BorderSize.six, 0, Color.Black ) );
                }
            }

            //konszig táblázat-BN
            _table.AutoFit = AutoFit.ColumnWidth;

            for ( int i = 0 ; i < _table.Rows.Count ; i++ )
            {
                _table.Rows[ i ].Cells[ 0 ].Width = 45;     //sorszám
                _table.Rows[ i ].Cells[ 1 ].Width = 210;    //megnevezés
                _table.Rows[ i ].Cells[ 2 ].Width = 60;     //hordó
                _table.Rows[ i ].Cells[ 3 ].Width = 50;     //sarzs
                _table.Rows[ i ].Cells[ 4 ].Width = 80;     //súly
                _table.Rows[ i ].Cells[ 5 ].Width = 160;    //h.típus
                _table.Rows[ i ].Cells[ 6 ].Width = 110;    //dátum
            }
            _table.AutoFit = AutoFit.ColumnWidth;
        }
Exemple #5
0
        MinBizDataTablazatFormazasa( Table _table )
        {
            _table.AutoFit = AutoFit.Contents;

            Border c = new Border( BorderStyle.Tcbs_none, BorderSize.seven, 0, Color.Black );
            _table.SetBorder( TableBorderType.InsideH, c );
            _table.SetBorder( TableBorderType.InsideV, c );
            _table.SetBorder( TableBorderType.Bottom, c );
            _table.SetBorder( TableBorderType.Top, c );
            _table.SetBorder( TableBorderType.Left, c );
            _table.SetBorder( TableBorderType.Right, c );
        }