Skip to main content
 
developerWorks
AIX and UNIX
Information Mgmt
Lotus
New to Lotus
Products
How to buy
Downloads
Live demos
Technical library
Training
Support
Forums & community
Events
Rational
Tivoli
WebSphere
Java™ technology
Linux
Open source
SOA and Web services
Web development
XML
My developerWorks
About dW
Submit content
Feedback



developerWorks  >  Lotus  >  Forums & community  >  Notes/Domino 4 and 5 Forum

Notes/Domino 4 and 5 Forum

developerWorks

  


Rich Text Field do not display appended text
Zac Douglas 23.May.13 11:33 PM a Web browser
Domino Designer -- LotusScript 5.0.13 Windows XP

Hi, I am new to lotus and using R5 for my developement. I have a rich text field in a form and would like to update the field with a text/string from another form via a action. How do i achieved it?

Dim session As New NotesSession
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim workspace As New NotesUIWorkspace
Dim uidoc As NotesDocument
Set db = session.CurrentDatabase
Set uidoc = workspace.CurrentDocument.document
Dim richStyle1, richStyle2 As NotesRichTextStyle
Set richStyle1 = session.CreateRichTextStyle
Set richStyle2 = session.CreateRichTextStyle
Dim richText As Variant

Dim rti As New NotesRichTextItem(uidoc, "employ")
Messagebox "aaa"
Set richText = uidoc.GetFirstItem("REmploy1")

richStyle1.Bold = True
richStyle1.NotesFont = FONT_ROMAN
richStyle1.FontSize = 12

richStyle2.Bold = False
richStyle2.NotesFont = FONT_ROMAN
richStyle2.FontSize = 12
If (richText.Type = 1) Then
Set richtext = rti
count = 0
cNum = 0
Forall ct In docCan.Eh_No
cNum = cNum + 1
count = count + 1
End Forall

count = count - 1

For i=0 To count
cnum = cnum -1
If (Not docCan.EH_No(cnum)="") Then
If i = 0 Then
Call richText.AppendStyle(richStyle1)
Call richText.AppendText(docCan.EH_Case_1(cnum) & " - " & docCan.EH_Case_2(cnum) & " " & docCan.EH_Case_3(cnum))
Call richText.AddNewLine(1)
Call richText.AppendText("Position " & docCan.EH_Case_4(cnum))
Call richText.AddNewLine(1)
Call richText.AppendText("Duties - " )
Call richText.AppendStyle(richStyle2)
Call richText.AppendText(docCan.EH_Case_5(cnum))
Call uidoc.save(True,False)
Else
Call richText.AppendStyle(richStyle1)
Call richText.AddNewLine(2)
Call richText.AppendText(docCan.EH_Case_1(cnum) & " - " & docCan.EH_Case_2(cnum) & " " & docCan.EH_Case_3(cnum))
Call richText.AddNewLine(1)
Call richText.AppendText("Position " & docCan.EH_Case_4(cnum))
Call richText.AddNewLine(1)
Call richText.AppendText("Duties - " )
Call richText.AppendStyle(richStyle2)
Call richText.AppendText(docCan.EH_Case_5(cnum))
Call uidoc.save(True,False)
End If
Else
Exit For
End If
Next
End If
Messagebox richText.GetFormattedText( True,0 )

Set REmploy1 = richText


My current code do not reflect the appended text but runs through the lines of codes. Any advise?




Rich Text Field do not display appe... (Zac Douglas 23.May.13)
. . RE: Rich Text Field do not display ... (Karl-Henry Mart... 7.Jun.13)






  Document options
Print this pagePrint this page

 Search this forum

  Forum views and search
Date (threaded)
Date (flat)
With excerpt
Author
Category
Platform
Release
Advanced search


 RSS feedsRSS
All forum posts RSS
All main topics RSS
More Lotus RSS feeds

 Resources
Forum use and etiquette
Native Notes Access
Web site Feedback

  Lotus Support
Lotus Support
Product support pages index
Search knowledge base (Technotes)
Search support downloads
Lotus Support RSS

 Wikis
IBM Composite Applications
IBM Mashup Center
IBM Connections
IBM Docs
IBM Forms
IBM Mobile Connect
IBM Sametime
IBM SmartCloud for Social Business
IBM Web Experience Factory
Lotus Domino
Lotus Domino Designer
Lotus Expeditor
Lotus Foundations
Lotus iNotes
Lotus Instructor Community Courseware
Lotus Notes
Lotus Notes & Domino Application Development
Lotus Notes Traveler
Lotus Protector
Lotus Quickr
Lotus Symphony
IBM Web Content Manager
WebSphere Portal

 Lotus Forums
Notes/Domino 9.0
Notes/Domino 8.5 + Traveler
Notes/Domino XPages development forum
Notes/Domino 8
Notes/Domino 6 and 7
Notes/Domino 4 and 5
IBM Connections
IBM Forms
IBM Mobile Connect
IBM Sametime
IBM SmartCloud Notes
IBM SmartCloud Meetings
IBM Web Content Manager
Lotus Domino Document Manager
Lotus e-learning
Lotus Enterprise Integration
Lotus Expeditor
Lotus Protector
Lotus Quickr
Lotus SmartSuite
Lotus Symphony
Lotus Symphony Developer Toolkit Support
Lotus Workflow