Internal use only. This function clears all the time slices of the appointment rule.
object.ClearSlices
Part | Attribute | Type | Description |
---|---|---|---|
object |
Required | The object always implements the
ISAppointmentTemplateDPP interface |
Clear all the time slices of the appointment rule.
'variable CurrentTemplate supports interface ISAppointmentTemplateDPP
Dim aCurrentTemplate
Dim aMessage
Dim aPOS
Dim aProvider
Dim i
Dim aAppointmentSlice
Set aCurrentTemplate = Profile.Variable("CurrentTemplate").Value
aMessage = "Appointment Template: " & vbNewLine &_
"Date: " & aCurrentTemplate.Date & vbNewLine
if aCurrentTemplate.ProviderID > 0 then
set aProvider = Profile.LoadProviderById(aCurrentTemplate.ProviderID)
aMessage = aMessage & "Provider: " & aProvider.FullName & vbNewLine
end if
if aCurrentTemplate.PosID > 0 then
set aPOS = Profile.LoadProviderById(aCurrentTemplate.PosID)
aMessage = aMessage & "POS: " & aPOS.Code & vbNewLine
end if
aMessage = aMessage & vbNewLine & vbNewLine &_
"The number of the appointment time slices is " & aCurrentTemplate.SlicesCount
for i = 0 to aCurrentTemplate.SlicesCount -1
set aAppointmentSlice = aCurrentTemplate.Slices(i)
aCurrentTemplate.ClearSlices
aMessage = aMessage & vbNewLine &_
"The time slices were successfully cleared"
next
Profile.MsgBox(aMessage)
In Profile Client v8 on User Interface Appointment Rule Time Slices can be found in
.