开发者

How do I add put a border around every 2 lines in excel worksheet

开发者 https://www.devze.com 2022-12-20 13:15 出处:网络
can someone please give me some guidelines on this. I\'m fairly new to VBA. After outputing data to a worksheet, i wan开发者_StackOverflow中文版t to format it.

can someone please give me some guidelines on this. I'm fairly new to VBA.

After outputing data to a worksheet, i wan开发者_StackOverflow中文版t to format it.

How do I add put a border around every 2 lines in an excel worksheet using VBA?

regards

Kojo


By using the conveniently named method.

Dim i As Long

For i = 1 To 10 Step 2
  Me.Range(Me.Cells(i, 1), Me.Cells(i + 1, 10)).BorderAround xlSolid, xlMedium
Next
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号