Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / October 2006

Tip: Looking for answers? Try searching our database.

problem with wordwrap property

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
anita - 09 Oct 2006 10:52 GMT
I add a table in my documents but I want to avoid of wordwrapping in my
table
so I set ACell.WordWrap = false for all my cells but it doesnot still
working;

ATabel := ADoc.tables.Add(ARange, 2, 4, .....);
ATable.Rows.Item(1).Cells.Item(1) := 'very long text............';
ATable.Rows.Item(1).Cells.Item(1).WordWrap := False;
Doug Robbins - Word MVP - 10 Oct 2006 18:40 GMT
From my testing, it appears that you have to set the .FitText attribute as
well:

With ActiveDocument.Tables(1).Cell(1, 1)
   .WordWrap = False
   .FitText = True
   .Range.Text = "this should be too long to fit in the cell."
End With

What it does however is compress the text so that it fits on one line in the
cell which may make it unreadable.

Signature

Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

>I add a table in my documents but I want to avoid of wordwrapping in my
> table
[quoted text clipped - 4 lines]
> ATable.Rows.Item(1).Cells.Item(1) := 'very long text............';
> ATable.Rows.Item(1).Cells.Item(1).WordWrap := False;
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.