I've made use of the great support provided in this thread :
Limiting the number of appointments per a month per user
To add a function that checks the current user's existing appointment count for a given date range, and returns an error if they've scheduled the maximum number already. I need to make two further tweaks to the function that require capturing the following variables:
1. The DateTime the user is trying to schedule an appointment for.
2. The duration of appointment they are trying to schedule.*
*If I'm able to get the variables for the event "Start Date Time" and "End Date Time" into the function, I can calculate the duration easily.
I've searched, but I don't see where/how to pass the appointment's start time and duration into variables within the function. Any solution or a point in the right direction would be much appreciated!