Greetings.
I got a template in Word that contains a table.
When I put text into the table I do...
word_document_explaination.Range(loc1, loc2).InsertBefore(text)
Is there a way to add an row to the table?
If so. How?
Thanks.
Printable View
Greetings.
I got a template in Word that contains a table.
When I put text into the table I do...
word_document_explaination.Range(loc1, loc2).InsertBefore(text)
Is there a way to add an row to the table?
If so. How?
Thanks.
grab a refernce to the table (tables.item(tablenumber)) and use .rows.add
Use a counter to keep track of which row you are on
Dim wdAdvice As New Word.Document()
With wdAdvice.Tables.Item(5)
.Cell(RowNumber, ColumnNumber).Range.Text = Date.Now.ToShortDateString
.Cell(iCurrentRow, 1).Range.Paragraphs.PageBreakBefore = CType(True, Int32)
.Rows.Add()
End With
Haven“t got time until now to try it and it works great.
Thanks alot.
*bows*