LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 244
Default Excel VBA - Insert Word Table problem

Selection does not have a Tables property try

Set wdApp = CreateObject("word.application"
wdApp.Documents.Open("C:Attendance _ Note.doc").Application.Visible = Tru
With wdAp
..Visible = Tru
With .Selectio
..TypeText Text:="Attendance Note
..TypeParagrap
wdApp.documents(1).Tables.Add Range:=.Range, NumRows:=6, NumColumns:=
End Wit
End Wit

----- PaulC wrote: ----

I am trying to add a word table into a word document that opens from a
Excel97 macro. Everything works fine until I try to insert the table
The code is

Set wdApp = CreateObject("word.application"
wdApp.Documents.Open("C:Attendance _ Note.doc").Application.Visible
Tru

With wdAp
.Visible = Tru
With .Selectio
.TypeText Text:="Attendance Note
.TypeParagrap
.Tables.Add Range:=Selection.Range,NumRows:=6, NumColumns:=
End Wit
End Wit


This works except it will not insert the table. What have I misse
out

Pau


--
Message posted from http://www.ExcelForum.com


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Insert word to excel SLK Excel Discussion (Misc queries) 0 May 9th 08 01:44 AM
Insert Word Document into Excel Steve Blake Excel Discussion (Misc queries) 2 July 5th 07 12:10 PM
PROBLEM WITH EXCEL TABLE IN WORD mlamin Excel Discussion (Misc queries) 1 January 21st 07 01:52 PM
Link table from excel to word using word VBA [email protected] Excel Discussion (Misc queries) 7 January 9th 07 05:57 PM
Problem with linked Excel table in a word Document jcarlos Excel Discussion (Misc queries) 1 August 5th 05 07:41 PM


All times are GMT +1. The time now is 03:05 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"