![]() |
|
#9
|
||||
|
||||
|
Try:
Code:
Sub FormatRows()
Dim i As Long, StrRows As String
If Selection.Information(wdWithInTable) = False Then Exit Sub
StrRows = InputBox("Please input the row #s to process." & vbCr & "(e.g. 1,2,3,5)")
On Error Resume Next
With Selection.Tables(1)
For i = 0 To UBound(Split(StrRows, ","))
With .Rows(Trim(Split(StrRows, ",")(i)))
.Borders(wdBorderLeft).ColorIndex = wdWhite
.Borders(wdBorderRight).ColorIndex = wdWhite
.Borders(wdBorderTop).ColorIndex = wdWhite
.Borders(wdBorderBottom).ColorIndex = wdWhite
.Borders(wdBorderVertical).ColorIndex = wdWhite
End With
Next
End With
End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Table formatting- column widths to percent
|
dherr | Word VBA | 3 | 05-02-2023 09:37 AM |
| Want a quotient using a constant to show up in column c each time a number is added to column b | fibbermcghee | Excel | 2 | 12-09-2014 05:48 PM |
how to apply table style WITHOUT setting it as a table?
|
dylansmith | Excel | 9 | 05-16-2014 07:25 PM |
| Conditional Formatting: How to dynamically apply to an expanding table? | tinfanide | Excel | 0 | 10-18-2013 06:34 AM |
| Apply formatting html version | Kreol2013 | Word VBA | 0 | 08-26-2013 05:08 PM |