Domino 9 und frühere Versionen > ND6: Entwicklung

Antwortdokumente und Leser und Autorenfelder

<< < (8/11) > >>

DerAndre:
was liefert runonserver zurück?

cash:
Set agent = db.GetAgent("AgentAnonym")
   
   If agent.RunOnServer(doc.NoteID) = 0 Then
      Messagebox "Agent ran",, "Success"
   Else
      Messagebox "Agent did not run",, "Failure"
   End If   

liefert brav "Agent ran" zurück...

Gruß

Thomsas

cash:
testhalberr habe ich den Agenten direkt im Queryclose eingefügt

dabei kommt jetzt:

Error #91 Object Variable not set in line 20

Line 20:    parent.Status = respdoc.Status

Langsam macht mir das Entwicklen keinen Spaß mehr :-:


Fast Kompletter Code:

   Dim session As New NotesSession
   Dim db As NotesDatabase
   Dim agent As NotesAgent
   Dim respdoc As NotesDocument
   Dim parent As NotesDocument
   Set db = session.CurrentDatabase
   Set agent = session.CurrentAgent
   ' Set respdoc = db.GetDocumentByID(agent.ParameterDocID) ' wenn über Agent ausgeführt
   
   
   'Set respdoc = db.GetDocumentByUNid(Source.Document.UniversalID)

   Set parent = db.GetDocumentByID(Source.Document.ParentDocumentUNID)

DAU-in:
wo setzt du respdoc?

grüsse

dau-in

cash:
Guter Einwand  ???

Wie sieht es mit

   Set respdoc = db.GetDocumentByUNid(Source.Document.UniversalID)

Der Fehler bliebe in diesen Fall identisch

Thomas

Navigation

[0] Themen-Index

[#] Nächste Seite

[*] Vorherige Sete

Zur normalen Ansicht wechseln