Problem creating a field in Word from LotusScript

Hi folks

I’m using LotusScript to create a Word document that summarizes the selected documents in Notes. I use a table to store every Notes document in a row, and the relevant fields of each Notes document are stored in columns.

The problem comes when I need to add a final row with a total that adds all figures in the last row. I need to add a computed field with the formula “=d2+d3+…+dn” but I can’t. I can only add a text field and store text in it. I’m not able to “transform it” in a computed field. With this code, I just have a text field:

Set Field = MSWORD.Selection.FormFields.Add(MSWORD.Selection.Range, 70)

MSWORD.ActiveDocument.FormFields(1).Result = “=D2+D3+D4”

In VBS, doing this makes the trick of “transform it” into a computed field:

Set myFormField = ActiveDocument.FormFields.Add(Range:=Selection.Range,Type:=wdFieldFormTextInput)

myFormField.TextInput.EditType Type:=wdCalculationText,Default:=“=d1 + d2”,Format:=“#.##0,00 €;(#.##0,00 €)”, Enabled:=False

But I can’t make a similar code in LotusScript. Can someone help me with this?