Format of Rows Added to a Table 
Author Message
 Format of Rows Added to a Table

I have added row to an existing table, which had only 1 row. That row was
formatted with a pattern of 25%, and the text was centered. All my added
rows inherited that same format, which is not what I wanted. I wanted my
added row to have no shading, to not be centered either vertically or
horizontilly. How can I set the formatting for my added rows?


Wed, 15 Oct 2003 22:26:30 GMT  
 Format of Rows Added to a Table

Set myNewRange = myTbl.Range
With myNewRange
   .MoveStart Unit:=wdRow   'Range is whole table minus first row
   .Shading.Texture = wdTextureNone
   .ParagraphFormat.Alignment = wdAlignParagraphLeft
   .Cells.VerticalAlignment = wdCellAlignVerticalTop
End With

Quote:

> I have added row to an existing table, which had only 1 row. That row was
> formatted with a pattern of 25%, and the text was centered. All my added
> rows inherited that same format, which is not what I wanted. I wanted my
> added row to have no shading, to not be centered either vertically or
> horizontilly. How can I set the formatting for my added rows?



Wed, 15 Oct 2003 22:52:05 GMT  
 Format of Rows Added to a Table
That worked great. But there are two additional problems. The first row was
a header. So that when the table extended to another page it was repeated,
and the header font was BOLD so I need to set font to normal. How can I do
that?  Can you recommend a good book about writing Word macros?


Quote:

> Set myNewRange = myTbl.Range
> With myNewRange
>    .MoveStart Unit:=wdRow   'Range is whole table minus first row
>    .Shading.Texture = wdTextureNone
>    .ParagraphFormat.Alignment = wdAlignParagraphLeft
>    .Cells.VerticalAlignment = wdCellAlignVerticalTop
> End With


> > I have added row to an existing table, which had only 1 row. That row
was
> > formatted with a pattern of 25%, and the text was centered. All my added
> > rows inherited that same format, which is not what I wanted. I wanted my
> > added row to have no shading, to not be centered either vertically or
> > horizontilly. How can I set the formatting for my added rows?



Wed, 15 Oct 2003 23:42:02 GMT  
 Format of Rows Added to a Table

Quote:
> The first row was a header. So that when the table extended to
> another page it was repeated, and the header font was BOLD so
> I need to set font to normal.

Do I understand this right -- you want the header to be bold on the
first page and not bold on the second?  Or you don't want a repeating
header, and you want all the other rows not bold?

Quote:
> Can you recommend a good book about writing Word macros?

Unfortunately, no.  I can recommend a few lousy ones....  ;)  But if
you send a separate post with 'books' in the subject, you'll probably
get other opinions.  For the basics -- which you're past -- I actually
found Microsoft's online programmer's guide to be most helpful, but
only the Word 97 version.  For everything beyond that, the most
helpful places for me have been these newsgroups and and MVP site
at http://www.mvps.org/word


------------- "Life is nothing if you aren't obsessed." --John Waters
---------------------------------------------------------------------

Quote:


> > Set myNewRange = myTbl.Range
> > With myNewRange
> >    .MoveStart Unit:=wdRow   'Range is whole table minus first row
> >    .Shading.Texture = wdTextureNone
> >    .ParagraphFormat.Alignment = wdAlignParagraphLeft
> >    .Cells.VerticalAlignment = wdCellAlignVerticalTop
> > End With


> > > I have added row to an existing table, which had only 1 row. That row
> was
> > > formatted with a pattern of 25%, and the text was centered. All my added
> > > rows inherited that same format, which is not what I wanted. I wanted my
> > > added row to have no shading, to not be centered either vertically or
> > > horizontilly. How can I set the formatting for my added rows?



Thu, 16 Oct 2003 09:17:35 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. adding a table row, without setting same defaults as previous row

2. row heights of table rows added by vba

3. Format last row in table

4. How to Create 2 column table and continue adding rows

5. Adding Rows to a Table

6. add text to table rows

7. Running a macro to add a row in a table

8. Add row to the end of a table

9. Adding row to table is Slooooooow!

10. Adding new rows to related tables on a dataset

11. Help adding Table Rows dynamically Please!

12. Adding blank row in table

 

 
Powered by phpBB® Forum Software