Example #1
0
        /// <summary>
        /// 设置模板显示表头列名
        /// </summary>
        /// <param name="columnsInfo"></param>
        private void setColumnsHeaderInfo(List <PrintColumnsInfo> columnsInfo, List <PrintColumnInfo> printCol = null)
        {
            switch (columnsInfo.Count)
            {
            case 0:
                this.dataGridView3.Columns.Clear();
                break;

            case 1:
                #region
                GlobalUtilOfPrint.CreateColumns1(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 2:
                GlobalUtilOfPrint.CreateColumns2(columnsInfo, this.dataGridView3, printCol);
                break;

            case 3:
                GlobalUtilOfPrint.CreateColumns3(columnsInfo, this.dataGridView3, printCol);
                break;

            case 4:
                GlobalUtilOfPrint.CreateColumns4(columnsInfo, this.dataGridView3, printCol);
                break;

            case 5:
                GlobalUtilOfPrint.CreateColumns5(columnsInfo, this.dataGridView3, printCol);
                break;

            case 6:
                GlobalUtilOfPrint.CreateColumns6(columnsInfo, this.dataGridView3, printCol);
                break;

            case 7:
                GlobalUtilOfPrint.CreateColumns7(columnsInfo, this.dataGridView3, printCol);
                break;

            case 8:
                GlobalUtilOfPrint.CreateColumns8(columnsInfo, this.dataGridView3, printCol);
                break;

            case 9:
                GlobalUtilOfPrint.CreateColumns9(columnsInfo, this.dataGridView3, printCol);
                break;

            case 10:

                #region

                GlobalUtilOfPrint.CreateColumns10(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 11:
                #region

                GlobalUtilOfPrint.CreateColumns11(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 12:
                #region
                GlobalUtilOfPrint.CreateColumns12(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 13:
                #region
                GlobalUtilOfPrint.CreateColumns13(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 14:
                #region
                GlobalUtilOfPrint.CreateColumns14(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 15:
                #region
                GlobalUtilOfPrint.CreateColumns15(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 16:
                #region
                GlobalUtilOfPrint.CreateColumns16(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 17:
                #region
                GlobalUtilOfPrint.CreateColumns17(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 18:
                #region
                GlobalUtilOfPrint.CreateColumns18(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 19:
                #region
                GlobalUtilOfPrint.CreateColumns19(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 20:
                #region
                GlobalUtilOfPrint.CreateColumns20(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 21:
                #region
                GlobalUtilOfPrint.CreateColumns21(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 22:
                #region
                GlobalUtilOfPrint.CreateColumns22(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            case 23:
                #region
                GlobalUtilOfPrint.CreateColumns23(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;


            case 24:
                #region
                GlobalUtilOfPrint.CreateColumns24(columnsInfo, this.dataGridView3, printCol);
                #endregion
                break;

            default:
                break;
            }
        }