OLE between Notes and Word

Posted on 2003-03-05
Medium Priority
Last Modified: 2013-12-18
I want to create a new word document with Lotus Notes and save there some entries from my Notes Form.

I created a button on a Form with the following
     Dim uiws As New NotesUIWorkspace
     Dim uidoc As NotesUIDocument    
     Dim doc As NotesDocument  
     Set uidoc = uiws.CurrentDocument
     Set doc = uidoc.Document
     Dim wordApp As Variant  
     Dim wordDoc As Variant      
     Dim firstname As String
        firstname = Cstr(doc.firstname(0))
     Set wordApp = CreateObject( "Word.Application" )
        Call  wordApp.Documents.Add( "SBOR_DCS.dot")
     Set  wordDoc = wordApp.Activedocument      
     wordApp.Visible = True
     wordDoc.insert ("Test") <-- don´t work.

After pressing button, Word is opening but I´m unable to insert text into the document.
Error : Instance member INSERT doesn´t exist!!

What is wrong???

Question by:sbor77
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Accepted Solution

AndrewJayPollack earned 100 total points
ID: 8072141
looks like the version of "word.application" doesn't create an object "worddoc" that has the method "insert"  somethings wrong with your use of the word object model.  
LVL 63

Assisted Solution

Zvonko earned 100 total points
ID: 8073372
In Word Application model does Document object not have an Insert method.

Correct call is:

wordApp.Selection.TypeText "Hallo test"


Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

  In today’s Arena we can’t imagine our lives without Internet as we are highly used to of it. If we consider our life style just for only 2 min we found that face to face communication is swapped by e-communication.  Every Where from Works place to…
This article covers general Notes 8.5 troubleshooting information including recreating the Notes\Data folder.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses
Course of the Month14 days, 5 hours left to enroll

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question