David W was telling us:
David W nous racontait que :
If i find word wrap has happened in a cell, i'll need merge some right
columns to avoid word wrap. So anyone could give me some suggestions ?
Play around with this:
'_______________________________________
Dim cellRge As Range
Set cellRge = Selection.Cells(1).Range
With cellRge
If .Characters.Count > 1 Then
If .Characters(1). _
Information(wdVerticalPositionRelativeToPage) < _
.Characters(.Characters.Count - 1). _
Information(wdVerticalPositionRelativeToPage) Or _
.Paragraphs.Count > 1 Then
MsgBox "Cell text is on at least two lines, merge!"
Else
MsgBox "Cell text is on one line, no merge!"
End If
Else
MsgBox "Cell is empty, no merge!"
End If
End With
'_______________________________________
--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
[email protected]
Word MVP site:
http://www.word.mvps.org