Development notes on how to potentially implement this.
Open the Create Mail Merge agent in Lotus Domino Designer.
1) Take a copy of the MergeXLSpreadsheet class, paste it back in and rename it e.g. MergeSymphonySpreadsheet
2) Make some changes to customise the class for your own requirements:
The "New" subroutine should load the spreadsheet file from the provided filename and perform any other initialisation. Store the filename and any other state you require in object variables.
%REM
Constructor
Description: Opens the specified filename as a spreadsheeet, accessing the active worksheet
%END REM
Public Sub New(strXLFilename As String, readOnly As Boolean)
...
End Sub
Implement the "LastDataRowNo", "CellText", to return the required values, and the "Delete" function to cleanup afterwards, the existing "FindTokens" function should work fine if the CellText function is implemented correctly.
%REM
Property Get CellText
Description: For a worksheet row number and column number, the cell
text including formatting (first row/column is 1)
%END REM
Public Property Get CellText(rowNo As Long, colNo As Long) As String
...
End Sub
%REM
Property Get LastDataRowNo
Description: For the specified worksheet column number, derive the
last row number which contains some data (first column is 1)
%END REM
Public Property Get LastDataRowNo(colNo As Long) As Long
...
End Sub
%REM
Destructor
Description: Cleanup variables, close open processes and file locks
%END REM
Sub Delete()
...
End Sub
3) Lastly, in the "Initialise" subroutine of the agent, modify the MergeXLSpreadsheet call to use your new class:
'Open the excel workbook to the active sheet
Dim xlSpreadSheet As New MergeXLSpreadsheet(strXLFilename, True)
4) Test in your Lotus Notes client with 'Debug LotusScript' turned on and running the agent, add a breakpoint at this line and step through it.