Hi,
auch auf die Gefahr hin, dass ich mich wiederhole: Man kann mit @DbLookup Rich Text Felder auslesen, das habe ich schon wiederholt gemacht.
Und zwar so:
Du erstellst ein Rich Text Feld in einer Maske und gibt als Vorgabewert folgendes ein:
@DbLookup("","";"Bilder";"Firma A","Body")
Das holt Dir dann aus einem Konfig.-Dokument, in dem Bilder verwaltet werden, das Bild. Achtung: Das Feld Body darf NICHT als Spalte in der View stehen!
In der Lotus Notes Knowledge Base gibt es dazu folgendes (#111833):
@DbLookup Fails to Return Rich Text Field
Problem:
You have a rich text field that correctly references another rich text field using @DbLookup. For example, in the following formula "richtext" is the name of a rich text field in the database db.nsf.
@DbLookup("":"NoCache";"db.nsf";"View by Category";"Smith";"richtext")
When executed, however, the formula yields a null value without an error message.
Solution:
If the view specified in the @DbLookup references the rich text field as part of a column definition, a null string results. Rich text fields cannot be displayed in a view, and therefore should not be referenced in a view column definition.
However, @DbLookup will retrieve a field as it appears in a view before it references fields as they appear in a document. A possible workaround is to remove the column in question from the view, so that Notes is forced to look at the rich text field as it appears in the document. Refer below for some limitations with this approach.
Supporting Information:
Using @DbLookup to pull information from a RTF is not supported because of certain limitations. Refer to the technotes listed in the Related Documents section for more information on the limitations.
For the most part, however, an RTF can use @DbLookup as a default formula to pull information from another RTF provided that the following are true:
- The RTF being looked up is a single RTF that contains less than 42K worth of data.
and
- The RTF being looked up is not referred to in the lookup view.
Übrigens: Mit LotusScript könnt Ihr das so nicht machen. Wenn Ihr ein Rich Text Item setzt, steht das erst zur Verfügung, nachdem das Dokument im Backend gespeichert wurde.
Andreas