Dim st5 As XLS.Style = Book.NewStyle
fnt5 = New Font("微软雅黑",8)
st5.Font = fnt52
st5.BackColor = Color.Bisque
st5.ForeColor = Color.black '
For i As Integer = 0 To 15
Sheet(4, i).Style = st5 '
next
然后想再加边框,
dim st6 As XLS.Style = Book.NewStyle
st6.BorderTop = XLS.LineStyleEnum.Thin
st6.BorderBottom = XLS.LineStyleEnum.Thin
st6.BorderLeft = XLS.LineStyleEnum.Thin
st6.BorderRight = XLS.LineStyleEnum.Thin
For i As Integer = 0 To 15
Sheet(4, i).Style = st6 '
next
现在这样做,就前面的st5的样式就被覆盖了。