![]() |
|
|
|
#1
|
|||
|
|||
|
Use whichever method you prefer, however to show that mine will work, I've uploaded two files you can use to illustrate. Save the template in the root "D" drive or change the code as required. |
|
#2
|
|||
|
|||
|
Thank you for showing me your example, I will will have a play around with it
|
|
#3
|
|||
|
|||
|
I have tried to use your code on my spreadsheet but I cant get it to work
![]() For the first part of the code I have put Code:
Dim AppWord As Object
Dim oDoc As Object
Dim oTbl As Object
Dim oRng As Object
Dim lngIndex As Long, lngObjectives As Long
On Error Resume Next
Set AppWord = GetObject(, "Word.Application")
If Err Then
Set AppWord = CreateObject("Word.Application")
End If
AppWord.Visible = True
On Error GoTo 0
Set oDoc = AppWord.Documents.Add("Pathway to template document")
Set oTbl = oDoc.Tables(8)
With oTbl
.Cell(2, 2).Range.Text = combo_Obj1_Reg.Text
.Cell(3, 2).Range.Text = combo_Obj1_RegC.Text
.Cell(4, 2).Range.Text = txt_Obj1Nar.Text
.Cell(5, 2).Range.Text = txt_Obj1Sum.Text
.Cell(6, 2).Range.Text = txt_Obj1_irr.Text
.Cell(7, 2).Range.Text = txt_Obj1_Post.Text
.Cell(8, 2).Range.Text = txt_Obj1_Att1.Text
.Cell(9, 2).Range.Text = txt_Obj1_Att2.Text
.Cell(10, 2).Range.Text = txt_Obj1_Att3.Text
End With
|
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Blury Excel Tables in Word
|
zachg18 | Word | 1 | 07-15-2013 11:10 PM |
| how to copy all ms word tables into excel | rehan129 | Word | 0 | 01-28-2012 10:17 AM |
Excel Tables to MS Word
|
ripcurlksm | Word Tables | 2 | 09-09-2011 04:59 AM |
using checkboxes to delete tables
|
atfresh | Word Tables | 1 | 06-19-2011 09:13 PM |
working with excel tables in MS word
|
radman154 | Word Tables | 1 | 03-25-2011 12:04 AM |