回复 1楼czpi的帖子
感谢你的问题反馈,我模拟你的代码如下:
- Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
- Dim w_Range As FarPoint.Win.Spread.Cell
- w_Range = Me.FpSpread1.ActiveSheet.Cells(2, 2)
- Dim red As New FarPoint.Win.ComplexBorderSide(Color.Red)
- Dim w_cBorder As New FarPoint.Win.ComplexBorder(red, red, Nothing, Nothing)
- w_Range.Border = w_cBorder
- End Sub
复制代码
实现效果图如下:
所以,请问您的问题是 Cell[2,2]的上边框遮盖住了 Cell[1,2]的下边框了吗?如果是,下面这段代码可以解决您的问题,需要设置 Cell[1,2]的下边框:
- Dim w_Range As FarPoint.Win.Spread.Cell
- w_Range = Me.FpSpread1.ActiveSheet.Cells(2, 2)
- Dim red As New FarPoint.Win.ComplexBorderSide(Color.Red)
- Dim w_cBorder As New FarPoint.Win.ComplexBorder(red, red, Nothing, Nothing)
- w_Range.Border = w_cBorder
- Dim green As New FarPoint.Win.ComplexBorderSide(Color.Green)
- Dim w_cBorder1 As New FarPoint.Win.ComplexBorder(green, Nothing, Nothing, green)
- Me.FpSpread1.ActiveSheet.Cells(1, 2).Border = w_cBorder1
复制代码 |