home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / xbase / library / fox / workgrp / splusall.prg < prev    next >
Text File  |  1993-09-02  |  3KB  |  130 lines

  1. SET LIBRARY TO foxmapi.fll
  2.  
  3. #DEFINE    sp_no_request_sent                0
  4. #DEFINE    sp_no_response                    1
  5. #DEFINE    sp_positive_response            2
  6. #DEFINE    sp_negative_response            3
  7. #DEFINE    sp_ambiguous_response            4
  8.  
  9. #DEFINE    sp_response_requested            65536
  10.  
  11. #DEFINE    sp_private                        1
  12. #DEFINE    sp_tentative                    4
  13.  
  14. #DEFINE    sp_prv_project                    2
  15.  
  16. #DEFINE    sp_boss_wants_copy                1
  17.  
  18. #DEFINE    sp_default_alarm                4096
  19.  
  20. #DEFINE    sp_mod_flags                    65536
  21. #DEFINE    sp_mod_assoc                    131072
  22. #DEFINE    sp_mod_attendees                262144
  23. #DEFINE    sp_mod_text                        524288
  24. #DEFINE    sp_mod_times                    4194304
  25. #DEFINE    sp_mod_project_name                8388608
  26. #DEFINE    sp_mod_priority                    16777216
  27.  
  28. #DEFINE    sp_mod_all                        33488896
  29.  
  30. #DEFINE    sp_suppress_recipients            4096
  31.  
  32. #DEFINE        sp_e_inv_sent_for            10000
  33. #DEFINE        sp_e_not_installed            10005
  34. #DEFINE        sp_e_no_items                10010
  35. #DEFINE        sp_e_no_schedule            10015
  36. #DEFINE        sp_e_no_privilege            10020
  37. #DEFINE        sp_e_address_format            10025
  38. #DEFINE        sp_e_user                    10030
  39. #DEFINE        sp_e_item                    10035
  40. #DEFINE        sp_e_itype                    10040
  41. #DEFINE        sp_e_flags                    10045
  42. #DEFINE        sp_e_assoc                    10050
  43. #DEFINE        sp_e_organizer                10055
  44. #DEFINE        sp_e_org_id                    10060
  45. #DEFINE        sp_e_attendees                10065
  46. #DEFINE        sp_e_time                    10070
  47. #DEFINE        sp_e_priority                10075
  48. #DEFINE        sp_e_month                    10080
  49. #DEFINE        sp_e_restriction            10085
  50. #DEFINE        sp_e_alarm_ring_in_past        10090
  51. #DEFINE        sp_e_not_online                10095
  52.  
  53. #DEFINE        success_no_schedule            10100
  54.  
  55.  
  56. hmapisession = 0
  57.  
  58. retval=mplogon(0, "", "", 3, 0, @hmapisession)
  59.  
  60. =mpcursor("MapiRecip", "")
  61. =mpcursor("SPlusRest", "SPlusRest")
  62.  
  63. SELECT mapirecip
  64. SET SAFETY OFF
  65. ZAP
  66. SET SAFETY ON
  67. APPEND BLANK
  68.  
  69. REPLACE reserved WITH 0
  70. REPLACE recipclass WITH 0
  71. REPLACE name WITH  ""
  72. REPLACE address WITH  ""
  73. REPLACE eidsize WITH  0
  74. REPLACE entryid WITH  ""
  75.  
  76. SELECT splusrest
  77. SET SAFETY OFF
  78. ZAP
  79. SET SAFETY ON
  80. APPEND BLANK
  81.  
  82. REPLACE reserved WITH  0
  83. REPLACE itemtype WITH  "Appt"
  84. REPLACE resttype WITH  "Day"
  85. REPLACE restdata WITH  ""
  86.  
  87. hsession = 0
  88.  
  89. retval=spbegin(0, 0, 0, 0, @hsession)
  90.  
  91. lpszitemid=SPACE(1)
  92.  
  93. retval=spuserinfo(hsession, 0, "MapiRecip",  0, 0, "SPlusUser")
  94. WAIT WINDOW "return from SPUserInfo = " + STR(retval)
  95. SELECT splususer
  96. LIST
  97.  
  98. retval=spfindnext(hsession, 0, "MapiRecip", "SPlusRest", "", 0, 0, @lpszitemid)
  99. WAIT WINDOW "return from SPFindNext = " + STR(retval)
  100.  
  101. retval=spreadappt(hsession, 0, "MapiRecip", lpszitemid, 0, 0, "SPlusAppt", "SPlusAssoc", "SPlusAttd", "MapiAttd")
  102. WAIT WINDOW "return from SPReadAppt = " + STR(retval)
  103.  
  104. SELECT mapirecip
  105. LIST
  106. SELECT splusappt
  107. LIST
  108. SELECT splusassoc
  109. LIST
  110. SELECT splusattd
  111. LIST
  112. SELECT mapiattd
  113. LIST
  114.  
  115. SELECT splusappt
  116. GOTO TOP
  117. REPLACE TEXT WITH "Hello from foxprow"
  118.  
  119. retval=spsaveappt(hsession, 0, "MapiRecip", "SPlusAppt", "SPlusAssoc", "SPlusAttd", "MapiAttd", 0, 0, @lpszitemid)
  120. WAIT WINDOW "return from SPSaveAppt = " + STR(retval)
  121.  
  122. *retVal=SPDelete(hSession, 0, "MapiRecip", ItemId, 0, 0)
  123. *wait window "return from SPDelete = " + str(retVal)
  124.  
  125. retval=spend(hsession, 0, 0, 0)
  126. retval=mplogoff(hmapisession, 0, 0, 0)
  127.  
  128. SET LIBRARY TO
  129.  
  130.