General information
Category:
COM/DCOM and OLE Automation
>Thanks, Mark. That's the way I'd always handled tables, but this latest app. has a lot of template docs that the clients can change. Obviously they want to see a "real table" in place in their template. And (as you also mention) sometimes these tables have a lot of static data.
>
>
>>I bookmarked an empty table that would need rows added and data filling the cells. After reading the article, I removed the empty table from the Word document and just put a text placeholder in the doc. I then do a search for that placeholder, delete it, the insert the table according to the article.
>>
>>I would like to figure out how to do it the other way in case I have tables that have mostly static data that I may need to add a minimal amount of data to. Actually I have figured a way to do this but it is not as clean as creating the entire table [string] in VFP, sending it to Word, then have Word convert it to a table.
>>
This will create table object:
poTable = ThisForm.poWord.ActiveDocument.Bookmarks("tablebench").Range.Tables(1)
Where "tablebench" is a bookmark you add to that table.
Now you can talk to your table like this:
?poTable.cell(1, 1).range.text
HTH Mark
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only