In order to keep your schedule not too hasty, you had better keep enough free time between Outlook appointments, such as at least 30 minutes. Now, this post will let your Outlook to warn you if there is no enough free time between appointments.
Unquestionably, you should make your schedule reasonably. One of the most vital rules is to keep enough free time between appointments, preventing making your schedule too hasty. Otherwise, you will find that, most of time, you may miss or can’t attend some appointments in time. But, by default, Outlook can only auto test if there are conflicts appointments. It cannot check if appointments are too close to each other. Thus, thereinafter, we will share you a method to achieve this feature.
Get Warned If There Is Not Enough Time between Appointments
- In the first place, launch your Outlook program.
- Then in the following Outlook window, press “Alt + F11” key buttons.
- Next, you will enter the “Microsoft Visual Basic for Applications” window, in which you need to open the “ThisOutlookSession” project.
- Subsequently, copy the following VBA code into this project.
Private WithEvents objInspectors As Inspectors Private WithEvents objAppointment As AppointmentItem Private Sub Application_Startup() Set objInspectors = Outlook.Application.Inspectors End Sub Private Sub objInspectors_NewInspector(ByVal Inspector As Inspector) If TypeName(Inspector.CurrentItem) = "AppointmentItem" Then Set objAppointment = Inspector.CurrentItem End If End Sub Private Sub objAppointment_PropertyChange(ByVal Name As String) Dim dStartTime As Date Dim dEndTime As Date Dim objAppointments As Items Dim strFilter As String Dim objFoundAppointment As AppointmentItem Dim strMsg As String Dim nWarning As Integer If Name = "Start" Or Name = "End" Then dStartTime = DateAdd("n", -30, objAppointment.start) dEndTime = DateAdd("n", 30, objAppointment.End) Set objAppointments = Application.ActiveExplorer.CurrentFolder.Items strFilter = "[End] >= " & Chr(34) & dStartTime & Chr(34) & " OR [Start] <= " & Chr(34) & dEndTime & Chr(34) Set objFoundAppointment = objAppointments.Find(strFilter) If Not (objFoundAppointment Is Nothing) Then strMsg = "Too Hasty Schedule: " & vbCrLf & vbCrLf & "No enough free time between each appointment!" & vbCrLf & "Please change the current appointment's time!" nWarning = MsgBox(strMsg, vbExclamation + vbOKOnly, "Smart Schedule") End If End If End Sub
- After that, you ought to sign this code. Just click “Tools” and choose “Digital Signature” option, and lastly follow onscreen instructions to complete it.
- Later you can exit the VBA editor window and proceed to alter your Outlook macro settings to enable signed macros.
- Finally you could restart your Outlook to activate this new macro.
- From now on, every time you create or change an appointment, Outlook will auto check if there are any existing appointments whose time is too close to the current one. If so, you will get a warning like the following screenshot:
Combat against Outlook Data Loss
Without any doubts, one of the best ways to fight against Outlook data corruption or data loss is to make consistent and up-to-date PST data backups. In addition, it is also recommended to get hold of a preeminent repair tool, such as DataNumen Outlook Repair. It can repair PST errors and damage without any hassles.
Shirley Zhang is a data recovery expert in DataNumen, Inc., which is the world leader in data recovery technologies, including corrupt sql and outlook repair software products. For more information visit www.datanumen.com
Leave a Reply