Solved

4.5: Font problem in RTFs

Posted on 2000-05-16
7
224 Views
Last Modified: 2013-12-18
Following constellation on a 4.5 client:

-we have 5 richtext field in a table, each in a different column. All of them are computed and helv 8
-those fields are filled through the method getitemvalue from notesdocument class. It gets data from different fields of different sizes
- the richtext fields are defined as notesrichtextitems and data is append through the appendtext and addnewline methods from notesrichtextitem class.

Now this data is always appended as helv 10, even that the fields are defined as helv 8.

Anyone has an idea what we can do to show it in the correct fontsize ?

0
Comment
Question by:Paebdb
7 Comments
 
LVL 5

Expert Comment

by:snocross
ID: 2813969
You can use NotesRichTextStyle to set the font when you write the text to the rich text field:

Sub Initialize
     Dim session As New NotesSession
     Dim db As NotesDatabase
     Set db = session.CurrentDatabase
     Dim doc As New NotesDocument(db)
     Call doc.AppendItemValue _
     ("From", session.UserName)
     Call doc.AppendItemValue _
     ("Subject", Inputbox("Subject?"))
     Call doc.AppendItemValue _
     ("Categories", Inputbox("Category?"))
     Dim richStyle As NotesRichTextStyle
     Set richStyle = session.CreateRichTextStyle
     richStyle.NotesFont = FONT_COURIER
     richStyle.FontSize = 14
     Dim richText As New NotesRichTextItem(doc, "Body")
     Call richText.AppendStyle(richStyle)
     newPara = Inputbox _
     ("Paragraph of text for ""Body"" item")
     firstPara = True
     While newPara <> ""
          If firstPara Then
               firstPara = False
          Else
               Call richText.AddNewLine(2)
          End If
          Call richText.AppendText(newPara)
          newPara = Inputbox _
          ("Paragraph of text for ""Body"" item")
     Wend
     Call doc.Save(True, False)
End Sub
0
 
LVL 2

Expert Comment

by:amit_dutta
ID: 2815802
Hello friends,

rich test style does not work with Notes 4.5. This feature was introduced in notes 4.6.

So u will g\have to live with it, or upgrade to 4.6 or above.

0
 
LVL 2

Author Comment

by:Paebdb
ID: 2816155
I know that richtextstyle does not work for 4.5.
Upgrading is not an option, we have several thousands of installations which are surely not upgraded for this reason.
I wonder from where this helv 10 comes. Is it the standard setting ?
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 6

Accepted Solution

by:
ghassan99 earned 100 total points
ID: 2817052
Hi Bernd,

I checked this for u, I never used 4.5 myself, but I gathered that it is set to Helv 10, take a look at this solution, I dont know if it helps though:)

http://notes.net/46dom.nsf/55c38d716d632d9b8525689b005ba1c0/b3c8034d0a653c74852566250051f076?OpenDocument

Cheers,
-Gus
0
 
LVL 2

Author Comment

by:Paebdb
ID: 2832546
Gus, finally I can give you some points too :)

Thanx, my programmer just told me it worked perfectly !
How is live ? Did you persuade the british lady by now that germans are not that bad ? Hey and Bayern became champion this weekend !
0
 
LVL 6

Expert Comment

by:ghassan99
ID: 2832750
Hi Bernd,

Thanx for the pts:))

Ummm life is fine, although I ditched the German babe, Im now very attached to a new Leb girl, I think its about time to hang out with someone of my own skin! lol

It was amazing how Bayern clinched that title, I personally was very shocked, it was unbelievable...u know even Beckenbaur was too, he was in Singapore and his wife told him on the mobile, the guy couldnt believe it too.

Anyway, how r u?  How is DB?  Still in Spain?

Take care,
-Gus
0
 
LVL 2

Author Comment

by:Paebdb
ID: 2832757
Yup, last 5 days of work, then 1 month beach, from 1.July on I will work in Germany again.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

For users on the Lotus Notes 8 Standard client, this article provides information on checking the Java Heap size and adjusting it to half of your system RAM in attempt to get the Lotus Notes 8.x Standard client to run faster.  I've had to exercise t…
I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

920 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now