Das Notes Forum

Domino 9 und frühere Versionen => Entwicklung => Thema gestartet von: Don Pasquale am 06.12.02 - 15:12:00

Titel: Probleme mit REMINDER
Beitrag von: Don Pasquale am 06.12.02 - 15:12:00
Hallo liebe Notisten,

ich habe folgendes Script  ( http://www.eknori.de/tips/reminder.htm)
das einen Eintrag in den Kalender des Users macht.
Dieser Eintrag dient als Erinnerung für eine Wiedervorlage.

Ich habe damit aber 2 Probleme:

Wie kann ich diesen Eintrag löschen bzw. ändern ?
(Ich vermute ich benötige die Universal ID dieses Eintrags,
aber woher/ wie bekomme ich die ?)

Ich würde gerne das Symbol des Eintrags selbst setzen,
aber folgende Zeile bleibt ohne Auswirkungen :
     .ReplaceItemValue "ViewIcon", "01"


Hat dazu  jemand irgendeine Idee ?

Viele Grüße

Don Pasquale


Sub createReminder( dateTime As notesDateTime, JNAlarm As String, popUpStr As String, subjectStr As String, infoStr As String ,DocID As String)
   
   Dim sess As New NotesSession
   Dim userMailDb As New NotesDatabase( "", "" )
   Dim reminderDoc As NotesDocument
   Dim DTItem As NotesItem
   Call userMailDb.OpenMail
   If userMailDb.IsOpen Then
      Set reminderDoc = New NotesDocument( userMailDb )
      Dim s As New NotesSession
      Dim db As NotesDatabase
      Dim view As NotesView
      Dim doc As NotesDocument
      Dim rtItem As NotesRichTextItem
      Set db = s.CurrentDatabase
      Set view = db.GetView ("($AllDocID)")
      Set doc = view.GetDocumentByKey(DocID)
      
      With reminderDoc
         .Form = "Appointment"
         .ReplaceItemValue "$Alarm", 1
         .ReplaceItemValue "$AlarmDescription", poUpStr
         .ReplaceItemValue "$AlarmMemoOptions", ""
         .ReplaceItemValue "$AlarmOffset", 0
         .ReplaceItemValue "$AlarmUnit", "M"
'         .ReplaceItemValue "ViewIcon", "67"
         .ReplaceItemValue "ViewIcon", "01"
         .ReplaceItemValue "Location", ""
'         .ReplaceItemValue "ExcludeFromView", "D"
         .ReplaceItemValue "ExcludeFromView", "E"
         .ReplaceItemValue "NoticeType", "R"
         .ReplaceItemValue "tmpDoNotProcess", "1"
         .Subject = subjectStr
         .Alarms = JNAlarm
         .CalendarDateTime = dateTime.lsLocalTime
         .StartDate = dateTime.lsLocaltime
         .StartTime = dateTime.lsLocaltime
         .StartDateTime = dateTime.lsLocaltime
         .EndDate = dateTime.lsLocaltime
         .EndTime = dateTime.lsLocaltime
         .EndDateTime = dateTime.lsLocaltime
         .AppointmentType = "4"
      End With
      Set rtitem = New NotesRichTextItem( reminderDoc, "Body" )
      Call rtitem.AddNewLine( 1 )
      Call rtitem.AppendText( infoStr )
      Call rtitem.AddNewLine( 3 )
      Call rtitem.AppendText( "Bitte klicken sie hier, um das Dokument zu öffnen --> " )
      Call rtitem.AddTab( 1 )
      Call rtitem.AppendDocLink( doc, db.Title )
      reminderDoc.ComputeWithForm True,True
      reminderDoc.save True,False
      reminderDoc.PutInFolder( "$Alarms" )
      Print "Wiedervorlage erstellt"
   Else
      Print "Fehler: Kann die Maildatei nicht öffnen"
   End If
End Sub
Titel: Re:Probleme mit REMINDER
Beitrag von: Christopher am 06.12.02 - 20:12:54
Schau Dir mal das Beispiel von Eknoris Seite an. www.eknori.de evtl. hilft es Dir weiter.
Titel: Re:Probleme mit REMINDER
Beitrag von: Don Pasquale am 09.12.02 - 09:52:10
@Christopher

Das IST das Beispiel von eknori, (Quellenangabe hab ich nachgetragen) was ich nur noch ein bisschen
aufgebohrt habe.
Leider funktionieren eben o.g. Dinge nicht, vor allem, wenn der User den Wiedervorlagentermin ändert, dann hat er 2 Termine in seinem Kalender.

Ciao

Don Pasquale