MAPI Outlook "sync" with DBF / SQL

MAPI Outlook "sync" with DBF / SQL

Postby Jimmy » Mon Jan 23, 2023 7:46 pm

hi,

when use Codejock Calendar i can use MAPI or DBF / SQL as "Dataprovider"

when use DBF / SQL i can use MAPI in 2nd Thread to "sync" Outlook.PST
when Outlook is "open" i can "see" when it "sync" Appointment

to "sync" Outlook.PST to DBF / SQL i have to "compare" Appointment with Database
Question :
is there a other Way to get "last Change" in *.PST :?:

---

i do scan PST "backward" from "Startday" and than "compare" DBF

Code: Select all  Expand view
STATIC PROCEDURE Fillit( cStart, cEnd )
LOCAL oAppointment
LOCAL currentAppointment
LOCAL i, iMax
LOCAL oItem
LOCAL cFilter
LOCAL nTimeStart
LOCAL nEndStart
LOCAL cText

   IF SP_lUseMapi() = .T.
      IF InitMAPI()
         //    cFilter      := "[Start] >= '"+ cStart + "' and [Start] <= '"+ cEnd +"'"
         cFilter := "[Start] >= '" + cStart + "'"
         oAppointment := oNameSpace:getDefaultFolder( olFolderCalendar ):Items
         currentAppointment := oAppointment:Restrict( cFilter )

         iMax := currentAppointment:count()
         FOR i := 1 TO iMax
            oItem := currentAppointment:item( i )

            APPEND BLANK

            Read_Start( oItem )
            Read_End( oItem )
            Read_CreationTime( oItem )
            Read_LastModificationTime( oItem )
            Read_EntryID( oItem )
            Read_Subject( oItem )
            Read_Location( oItem )
            Read_Categories( oItem )
            Read_Body( oItem )
            Read_Duration( oItem )
            Read_AllDayEvent( oItem )
            Read_RecurrenceState( oItem )
            Read_ReminderMinutesBeforeStart( oItem )
            Read_BusyStatus( oItem )
            Read_Importance( oItem )
            Read_ReminderSet( oItem )
            Read_MeetingStatus( oItem )
            Read_Sensitivity( oItem )

            REPLACE OUTLOOK->USER WITH "LOKAL"
         NEXT

         ExitMAPI()
      ENDIF

      IF USED()
         CLOSE
      ENDIF
   ENDIF

RETURN
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 100 guests