Get the App
SLTechnology News&Howtos  ›  Development  › 

How Asp.net_Table controls cells to merge vertically

Shulou Source: shulou.com Published: 2022-06-03 06:57:24 09月23日 Update

This article mainly introduces "Asp.net_Table how to control cell vertical merging". In daily operation, I believe many people have doubts about how Asp.net_Table controls cell vertical merging. Xiaobian consulted all kinds of data and sorted out simple and easy-to-use operation methods. I hope it will be helpful for you to answer the doubts of "Asp.net_Table how to control cell vertical merging". Next, please follow the editor to study!

Solution, create a Table control handling class with the following code:

The copy code is as follows:

/ / related operation classes for table controls

/ / /

Public static class aspTable

{

/ / merge lines

/ / /

/ / copyright Information: http://www.qqextra.com, http://t.qq.com/ls_man, http://blog.csdn.net/ls_man 2013-06-21 14:20:36

/ Table

/ / start line

/ / end the line

/ / column indexes to be merged

Public static void SetRowSpan (Table tbl, int startRow, int endRow, int colIndex)

{

Int countRowSpan = 0

Int spanRow = startRow

String spanText = tbl.Rows [startRow] .Cells [colIndex] .text

For (int rowIndex = startRow; rowIndex = 0; iMurray -)

{

SetRowSpan (tbl, startRow, endRow, (int) al [I])

}

}

}

A few points to note, the start line is generally set to 1, because 0 is the title line; the end line is generally set to the total number of lines of Table-1 (the last line).

At this point, the study on "how Asp.net_Table controls the vertical merging of cells" is over. I hope to be able to solve everyone's doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!

Tags: Controls units vertical learning code start information more copyright list help practical same next one line content head line article scheme method Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Tech Info MariaDB Microsoft NVidia Xiaomi