Appointment Cancellations Time Limit

Is there a way to add a parameter so that people cannot cancel their appointments after they are within 24 hours? I see the option to allow people to cancel their own appointments, I would just like to limit that slightly.

Thanks!