Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 08-22-2016, 05:29 AM
macropod's Avatar
macropod macropod is online now Word table auto text alignment vs cell height Windows 7 64bit Word table auto text alignment vs cell height Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,363
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Graham,



I took the OP's specs at face value, allowing for the possibility of vertically-merged cells.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #2  
Old 08-22-2016, 06:39 AM
Grantsub Grantsub is offline Word table auto text alignment vs cell height Windows 10 Word table auto text alignment vs cell height Office 2013
Novice
Word table auto text alignment vs cell height
 
Join Date: Aug 2016
Posts: 6
Grantsub is on a distinguished road
Default

Thanks

The 6 point is actually the the table row height is .06cm can the code be changed to table rowhight < .06

I will try both of these expample tonight
Thanks you for assiting me , hopefullly saving hours of time ,
I will revert on out come

Regards

Last edited by Grantsub; 08-22-2016 at 10:45 AM.
Reply With Quote
  #3  
Old 08-22-2016, 10:22 AM
Grantsub Grantsub is offline Word table auto text alignment vs cell height Windows 10 Word table auto text alignment vs cell height Office 2013
Novice
Word table auto text alignment vs cell height
 
Join Date: Aug 2016
Posts: 6
Grantsub is on a distinguished road
Default

Paul can you allow me to contact your directly for a short time to work though this
Grant
Reply With Quote
  #4  
Old 08-22-2016, 03:05 PM
macropod's Avatar
macropod macropod is online now Word table auto text alignment vs cell height Windows 7 64bit Word table auto text alignment vs cell height Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,363
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Quote:
Originally Posted by Grantsub View Post
The 6 point is actually the the table row height is .06cm
which is even less than 6pt!!!. 1cm is 28.35pt, so .06cm is only 1.70pt. If you want to use centimetres instead of points for the row heights, change:
If oCel.Height > 6 Then
to:
If Round(oCel.Height, 1) > Round(CentimetersToPoints(0.06), 1) Then
using whatever the correct value is - I seriously doubt it's 0.06cm.

Please keep any discussions in the public forum.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote
  #5  
Old 08-22-2016, 11:27 PM
Grantsub Grantsub is offline Word table auto text alignment vs cell height Windows 10 Word table auto text alignment vs cell height Office 2013
Novice
Word table auto text alignment vs cell height
 
Join Date: Aug 2016
Posts: 6
Grantsub is on a distinguished road
Default

Thank you Paul and Graham
I see I didn’t describe the task sufficiently

I am looking for some code that will set alignment as the cell height but due to the the nature of the finished doc not all coloums and row alignment are the same , the script you wrote for me showed me the power of what it could do by some one more advanced than me ,

Below is a extract of a formatted word doc sample formatted correctly showing the final result required ,with the alignment of the txt in vaporous rows and columns different determined by the row height with the hacked up code i use at present one line at a time with me deciding which to use.

Below is sample of the different alignments in each row and column if different colors for the different alignments as example

So what I do now is select row and then press the recorded macro 1 or 2 which I determine by looking are the row height and pressing 1 or 2

What I want to do is select a single table on a page or multiple tables over many pages and press a macro to achieve the txt alignment
Attached Files
File Type: docm Sample.docm (68.3 KB, 12 views)
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Pasting text from Excel cell into word without creating a table, and keeping the in-cell formatting hanvyj Excel Programming 0 08-28-2015 01:15 AM
Word table auto text alignment vs cell height Row auto height markand_bhatt2008 Excel 1 04-29-2013 07:46 AM
Word table auto text alignment vs cell height table cell alignment issue gib65 Word 1 06-02-2012 03:03 PM
Word table auto text alignment vs cell height Table Text Alignment? Jazz43 Word Tables 2 08-19-2010 08:07 AM
Auto-populate an MS Word table cell with text from a diff cell? dreamrthts Word Tables 0 03-20-2009 01:49 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 04:06 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft