1

I am new to Domino designer and lotus script,

following my first question

1) How can I save form values to DB

2)How can I view DB( like MS access)

3) How to create view to retrieve values from DB

Googled for it but found a link to save to db solution.

I tried

Sub Click(Source As Button)
    Dim  myText As String
    Dim workspace As New NotesUIWorkspace
    Dim uidoc As NotesUIDocument
    Dim doc As NotesDocument
    Dim  enteredText As String

    Dim session As New NotesSession
    Dim db As NotesDatabase

    Set db = session.CurrentDatabase
    Set doc = New NotesDocument( db )
    doc.Form = "Main Topic"
    doc.Subject = "Here's a new document"
    Call doc.Save( False, False )//I think it is saving here but don'y know where it saves

    myText = Inputbox("insert some text :","Testing Heading","Default value",100,100)
    Msgbox "you have entered : "+myText 
    Set uidoc = workspace.CurrentDocument
    Set doc = uidoc.Document
    doc.addrfield = myText

    enteredText = doc.addrfield(0)
    Msgbox "Data entered in addrfield : "+ enteredText 
End Sub

But I don't know where it is saving my form fields

If possible please provide links to sites where DB and view are discussed along with codes.

Thanks in advance

The above one is solved! Thanks Knut

Edit 1:

I want to create a Java agent which will generate a text file (create a simple report) of the data in the database .

How can I add Java Agent ? How can I get access data(form fields) in the database ? Where should I place the java code?

4

1 回答 1

6

1)

Call doc.Save( False, False )之后添加doc.addrfield = myText。只有这样才能保存您在文档中所做的更改。

2) + 3)

在 Domino Designer 中创建一个表单“Main Topic”,并添加在打开具有 Form =“Main Topic”字段的文档时要查看的字段

在 Domino Designer 中创建一个视图。创建显示您在文档中创建的字段的列

4)

阅读http://www.redbooks.ibm.com/Redbooks.nsf/RedbookAbstracts/sg246854.html?OpenDocument作为经典 Notes 应用程序开发的介绍。

于 2015-01-21T10:57:05.610 回答