How to Import data from another database into the body of an open memo using an action button.

jpirozzolo
jpirozzolo used Ask the Experts™
on
Hi,

One of my last questions on EE was for some advice on sharing the stationery in Lotus Notes mail.  One of the experts very kindly offered a solution, as follows:

1. Create a central database containing stationary documents.
2. Add an action button to the mail template that prompts the user for the stationary, then import it into the body of an open memo. (imports such as text/images etc)

Lets say I have the central database up and running and I have a stationery item in there ready to be imported.

My question is, please could someone give me an example of how to import items using an action button from the seperate database into an open memo.

Thanks very much (in advance)

Kindest Regards,

Joe.

Currently using clients R4 and R5
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Commented:
Hi jpirozzolo,
in order to imidiately see the changes when you import the contents of RT item into the RT item in currently opened document you have to:
 - copy the rt item to an rt item in the currently opened doc
 - save the currently opened doc
 - close the doc
 - open the doc for editing

something like this:
      Set doc = uidoc.document
      ...
      Call notesRichTextItem.AppendRTItem( notesRichTextItem2 )
      Call doc.Save( True, False, True )
      doc.SaveOptions = "0"
      Call uidoc.Close
      Set newUIDoc = w.EditDocument( True, doc, False, "", True, True )

Hope this helps,
Marko
Sjef BosmanGroupware Consultant

Commented:
There are two options:
1) See Marko's story. By the way: when you can allow users to select the stationary BEFORE opening a new memo, they don't have to save and reopen the memo.
2) Using copy/paste from an opened stationary document to the new memo. You need to open the stationary document in edit mode, select the stationary text, copy to clipboard, switch to memo and paste it. AFAIK, much of this can be automated using LotusScript.

Regards,
   Sjef

Author

Commented:
Hi,  Sorry - not had a chance to test this out properly but its something for me to work on so far, and I thought i'd better close this now.

Thanks very much for all your help.

Best Regards,

Joe.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial