can't copy from Word document VBA excel form
this is my first post and i am new to VB.
I am using a VBA form through Excel.
I am trying to open a word document and copy the entire contents to a text box on my form.
here is my code:
Dim wrdApp As Object
Dim wrdDoc As Object
Set wrdApp = CreateObject("Word.Application")
wrdApp.Visible = True
Set wrdDoc = wrdApp.Documents.Open(PathToDocument)
'PathToDocument uses variables that are defined earlier. it works...
wrdDoc.Edit.SelectAll. 'here is my problem
TxtSummary.SelStart = 0
@ wrdDoc.Edit.SelectAll. I get an error "Object doesn't support this property or method."
How do I select and copy the text in my word document?
Thanks a bunch...
By cy163 in forum Database
Last Post: 10-15-2008, 11:54 AM
By pieeater3142 in forum VB Classic
Last Post: 06-04-2008, 02:28 PM
By francozola25 in forum VB Classic
Last Post: 04-22-2008, 04:09 AM
By partyk1d24 in forum .NET
Last Post: 08-09-2006, 05:07 PM
By Sasha Polinskaya in forum VB Classic
Last Post: 02-15-2002, 07:05 PM
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center