![]() |
|
![]() |
|
Thread Tools | Display Modes |
|
#1
|
||||
|
||||
![]()
Try:
Code:
Sub FixTableBorders() Application.ScreenUpdating = False Application.DisplayAlerts = False Dim Tbl As Table, Bdr As Border With ActiveDocument For Each Tbl In .Tables With Tbl For Each Bdr In .Borders With Bdr If .LineStyle = wdLineStyleSingle Then Select Case .LineWidth 'Case 2 To 6: .LineWidth = 8 Case wdLineWidth025pt, wdLineWidth050pt, wdLineWidth075pt: .LineWidth = wdLineWidth100pt End Select End If End With Next End With Next End With Application.DisplayAlerts = True Application.ScreenUpdating = True End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#2
|
||||
|
||||
![]()
Hi there,
I've tried to see if I could fix it, but I can't. I've tried also, is to remove ' before the Case 2 To 6: LineWidth = 8, so with the ' or without the ', It doesn't do anything. I've tested on a table that had some 075pt, and modified on the same row, by changing 075 for 050pt just on 1 cell, on a few rows. I feel it's closer to the solution. I'll try different things, but if you do, please let me know. Thank you soooooo much for trying to help me. I'm deeply appreciative. Cendrinne |
#3
|
||||
|
||||
![]() Quote:
Case 2 To 6: LineWidth = 8 does exactly the same thing as: Case wdLineWidth025pt, wdLineWidth050pt, wdLineWidth075pt: .LineWidth = wdLineWidth100pt Try: Code:
Sub FixTableBorders() Application.ScreenUpdating = False Application.DisplayAlerts = False Dim Tbl As Table, Bdr As Border, Cll As Cell With ActiveDocument For Each Tbl In .Tables For Each Cll In Tbl.Range.Cells For Each Bdr In Cll.Borders With Bdr If .LineStyle = wdLineStyleSingle Then Select Case .LineWidth Case wdLineWidth025pt, wdLineWidth050pt, wdLineWidth075pt: .LineWidth = wdLineWidth100pt End Select End If End With Next Next Next End With Application.DisplayAlerts = True Application.ScreenUpdating = True End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#4
|
||||
|
||||
![]() Quote:
OK let me try the above modified script. I'm thinking maybe it's because my operating system is in French, which I have not control on that. Believe me, I've tried many time to request an English operating system. Thank god I truly LOVE my job. Ok enough bla bla, let me test this. Crossing fingers. |
#5
|
||||
|
||||
![]()
I was crossing my fingers, hoping for the best. ==> WOW, Thank you!
I'm beyond words. I have tears in my eyes, so grateful. Was spending so much time fixing other people's documents when you have more than 25, it gets sooooo long. I'm so grateful to you. I will not forget you and your forum. I owe you. If there is a paying format to request help, please please let me know. I wish I could send you a private message, which I can't to you. But I feel I should pay something to you or have a subscription of some sort, I would pay (as long it's reasonable). p.s. I've look through the forum for any option to give a donation. I found it, but it's stuck on $5.00 so regardless what amount I chose, which I would give you more then $20, it goes to $5.00. So I'm just letting you know. |
![]() |
Tags |
helpme, if command, wdlinewidth |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
cell border lineweights | bkcell | Excel | 0 | 08-20-2017 09:55 AM |
Can I type over a cell with a border? | Juju37 | Excel | 0 | 01-20-2015 07:40 AM |
![]() |
msbytes | Word | 4 | 08-15-2011 09:21 AM |
![]() |
markg2 | Excel | 10 | 04-12-2011 05:05 PM |
![]() |
markg2 | Word Tables | 2 | 01-15-2010 05:22 PM |