To enhance user experience, a requirement was introduced to prevent users from registering for event sessions after they have ended. Utilizing the 'Default registration form with Sessions' from Microsoft, a JavaScript customization was added. This script activates after the form loads by subscribing to the 'd365mkt-afterformload' event. It checks session end dates and times against the current browser time (all users are in the New Zealand time zone) and hides any expired sessions from the UI, including the entire Sessions section if all sessions have expired. This ensures that users can only register for active sessions, streamlining the Event Registration process by removing unavailable options. The solution focuses on UI changes rather than server-side validation.
Login now to access my digest by 365.Training