I have run into a problem where by creating a new document directly causes no issues, however when trying to do this through a dialogbox in LotusScript, I get a Type Mismatch error. I tried to use LotusScript to create a new document but still get the same message.
Here is the LotusScript called from a Button on a Form:
Dim workspace As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Set uidoc = workspace.CurrentDocument
Call workspace.DialogBox("F_TSE",True,True,True,True,True,False,"New Entry",,True,True,False)
I have tried the following to try and simulate a fresh new document with the same Type Mismatch error:
Dim session as New NotesSession
Dim workspace As New NotesUIWorkspace
Dim db as NotesDatabase
Dim uidoc As NotesUIDocument
Set db = session.CurrentDatabase
Set uidoc = workspace.CurrentDocument
Dim doc as New NotesDocument( db )
Call workspace.DialogBox(“F_TSE”,True,True,True,True,True,False,“New Entry”,doc,True,True,False)
Would anyone have any ideas on why this only occurs when calling the dialogbox?