Use Dialogbox Within A Script Agent

If you are writing a LotusScript agent and need to prompt the user for some
input, you know you can use InputBox. But what about when you have a defined
list, and would like the user to select from that list.

On a form, you'd just use a DialogBox. You can also use a DialogBox within an
Agent. To do this, create a backend document using the NotesDatabase
CreateDocument method. This creates a document, but since it's not a UIDoc,
it's not seen by the user. Then call DialogBox, with the LAST PARAMETER of the
DialogBox call set to the document you just created.
Dim ws As New NotesUIWorkspace
Dim session As New NotesSession
Dim doc As NotesDocument
Dim iReturn As Integer
Dim currentdb As NotesDatabase

Set currentdb = session.CurrentDatabase

Set doc = currentdb.CreateDocument

iReturn = ws.DialogBox ( "dlgTest", True,
True, False, False,
False, False, "Testing" , doc)

If iReturn Then
Messagebox "Item Selected is : " +
doc.GetItemValue("TestList")(0), 64,
"Testing"
Else
Messagebox "You hit cancel", 64,
"Cancel"
End If

Dig Deeper on Domino Resources

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchWindowsServer

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchDataCenter

SearchContentManagement

Close