Hi there phinds, here is a little sample for u
VB Code:
'----------------------------------------
'- Name: peet
'- Web:
'- Company: PvP
'----------------------------------------
'- Notes: opens a word document using
' the MS Word object lib.
'----------------------------------------
Option Explicit
Private objWord As Word.Application
Private wd As Word.Document
Private Sub Command1_Click()
Dim myRange As Range
Dim sSearchfor As String
If objWord Is Nothing Then
Set objWord = CreateObject("Word.Application")
Else
Set objWord = GetObject(, "Word.Application")
End If
DoEvents
Set wd = objWord.Documents.Open("c:\Test.doc")
'here u can do stuff with the document
'using the wd object
'adding some text to it
wd.ActiveWindow.Selection.TypeText "ABCDEFGH peet was here ! :-)"
'when finished manipulating the document, u can show it To the user
objWord.Visible = True
'quit word
If Not (wd Is Nothing) Then Set wd = Nothing
If Not (objWord Is Nothing) Then objWord.Application.Quit
If Not (objWord Is Nothing) Then Set objWord = Nothing
End Sub
hope this can get u off to a good start