Open a written document from a navigator-button

i'm working with Notes 4.6.2a "developer-version" and WinNT 4.0. One of my forms contains only one rtf-field. The field-content should be variable but unique. The user now click on the navigator-button and immediately the form shall opens with the old textinput - i don't want an empty form. Is it possible? Please give me a code-example.
Many greetings and thanks a lot!
Ingo Schmökel
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.


If u are trying to create a form with default value in RT field then I don't think that is feasible...because Notes realizes the changes made to RT field only after saving and reloading the document...

Challenging !

Anyway Good Luck

May be you can create a backend document with the values you want in the RTField and then use the script to open that document which would contain the text that you want to have.

Good Luck !!!

I agree with Arunkumar's suggestion above -- your "new message" action can create a new NotesDocument item in the current database with LotusScript, use AppendRTItem to populate the rich text field, then open it for editing in the uidoc.  Something like this:

Sub Click (Source As Button)
dim ws as new notesuiworkspace
dim sess as new notessession
dim db as notesdatabase
dim getdoc as notesdocument
dim doc as notesdocument
dim uidoc as notesuidocument

set db = sess.currentdatabase
set doc = New notesdocument(db)

' -- get a handle to `getdoc` here...
' -- you didn't suggest a method so i'll
' -- assume it's from a db profile doc
set getdoc = db.getprofiledocument( "*** profile form name ***" )

doc.Form = " **form to use** "
dim thertf as new notesrichtextitem(doc, " *** name of field *** ")
dim getrtf as notesrichtextitem
set getrtf = getdoc.getfirstitem( "Name of field to grab" )
call doc.AppendRTItem( getrtf )
call True, False )
set uidoc = ws.editdocument( True, doc )

End Sub

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Lotus IBM

From novice to tech pro — start learning today.