フォーム 1 の body とフォーム 2 の body1 という名前の 2 つのリッチテキスト フィールドの内容を比較するスクリプトが必要です。リッチテキスト タイプのフィールドを含む 2 つのフォームを作成し、categerioze ビューを作成し、このビューで比較という名前のボタンを作成しました。このビューでは、これら 2 つのフィールドの内容を比較してメッセージに表示します。
Sub Click(Source As Button)
Dim session As NotesSession
Dim db As NotesDatabase
Dim dc As NotesDocumentCollection
Dim doc, doc1 As NotesDocument
Dim body, body1 As Variant
Dim view As NotesView
Dim rtitem As NotesRichTextItem
Set session = New NotesSession
Set db = session.CurrentDatabase
Set dc = db.UnprocessedDocuments
Set doc = dc.GetFirstDocument
Set doc1=dc.GetNextDocument(doc)
body = doc.GetItemValue( "body" )
Msgbox body( 0 ), ,"Richtext field of First form"
body1=doc1.GetItemValue("body1")
Msgbox body1( 0 ) ,, "Rich Text field of Second form"
'If body.value=body1.value Then
Msgbox"both are same"
'End If
Msgbox"both are different"
End Sub