View Single Post
 
Old 12-12-2011, 03:46 AM
tinfanide tinfanide is offline Windows 7 64bit Office 2010 32bit
Expert
 
Join Date: Aug 2011
Posts: 312
tinfanide is on a distinguished road
Default

Thanks for the binding reminder.
It seems to work without the reference.
In Excel VBA:
Code:
Sub lateBinding()

' no need to set reference to MS Word Object Library
Dim wrdApp As Object
Set wrdApp = CreateObject("Word.Application")
Dim wrdDoc As Object
Set wrdDoc = wrdApp.Documents.Add

wrdApp.Visible = True
wrdDoc.Sections(1).Range.Delete

With wrdDoc
    .Paragraphs.Add
    .Paragraphs(1).Range.Text = "Late Binding: no need to set reference to MS Word Object Library"
End With

Set wrdDoc = Nothing
Set wrdApp = Nothing

End Sub
Reply With Quote