Reputation: 1241
I have the following situation:
I need an action in the embedded view that do the following actions:
Best regards Robert
Upvotes: 1
Views: 1228
Reputation: 426
If you want the action in the embedded view, you can do this:
Create the action in the embedded view. Use formula to run an agent
@Command([RunAgent]; "(CreateNotes)")
The agent should look like this:
Dim personDoc As NotesDocument
Set personDoc = workspace.Currentdocument.Document
Dim notesDoc As New NotesDocument(app.CurrentDatabase)
Call notesDoc.Replaceitemvalue("Form", "Notes")
Call notesDoc.Replaceitemvalue("Person_ID", personDoc.ID(0))
Call workspace.Editdocument(True, notesDoc)
Upvotes: 1
Reputation: 30970
Add this button to your form Person, not into the embedded view. You can position the button right above or beneath the embedded view.
Let the new document inherit fields from Person document like the Person_ID field.
Upvotes: 2