![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
#3
| |||
| |||
|
|
Hello M O J O, From your post, my understanding on this issue is: you want to know how to capture the Save event of an Outlook.AppointmentItem object. If I'm off base, please feel free to let me know. To capture the Save event of an Outlook.AppointmentItem object, we need to register the Outlook.Appointment.Write event. According to the MSDN article http://msdn2.microsoft.com/en-us/lib...ffice.11).aspx and http://msdn2.microsoft.com/en-us/library/bb175138.aspx The Write event occurs when an appointment is saved, either explicitly (for example, using the Save or SaveAs method) or implicitly (for example, in response to a prompt when closing the item's inspector). Below is my test code of the event with VB.NET: Imports Outlook = Microsoft.Office.Interop.Outlook Public Class Form1 Public WithEvents appointment As Outlook.AppointmentItem Private Sub appointment_Write(ByRef Cancel As Boolean) Handles appointment.Write MessageBox.Show("write") End Sub Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim appItem As Outlook.Application = New Outlook.Application() appointment = appItem.CreateItem(Outlook.OlItemType.olAppointmen tItem) appointment.Subject = "test" appointment.Body = "test" appointment.Save() End Sub End Class The appointment object registers the Write event and show a message box "write" when the appointment is saved (appointment.Save()) Please have a try and let me know the result. If you have any other concern or need anything else, please feel free to let me know. Sincerely, Jialiang Ge (jialge (AT) online (DOT) microsoft.com, remove 'online.') Microsoft Online Community Support ================================================== For MSDN subscribers whose posts are left unanswered, please check this document: http://blogs.msdn.com/msdnts/pages/postingAlias.aspx Get notification to my posts through email? Please refer to http://msdn.microsoft.com/subscripti...ult.aspx#notif ications. If you are using Outlook Express/Windows Mail, please make sure you clear the check box "Tools/Options/Read: Get 300 headers at a time" to see your reply promptly. Note: The MSDN Managed Newsgroup support offering is for non-urgent issues where an initial response from the community or a Microsoft Support Engineer within 1 business day is acceptable. Please note that each follow up response may take approximately 2 business days as the support professional working with you may need further investigation to reach the most efficient resolution. The offering is not appropriate for situations that require urgent, real-time or phone-based interactions or complex project analysis and dump analysis issues. Issues of this nature are best handled working with a dedicated Microsoft Support Engineer by contacting Microsoft Customer Support Services (CSS) at http://msdn.microsoft.com/subscripti...t/default.aspx. ================================================== This posting is provided "AS IS" with no warranties, and confers no rights. |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |