Hi there,
I'm trying to see if it's at all possible to silently shorten the end time of an active booking in SRM. I can see that it's possible to do this using the reservation action script while interacting with the UI. I have not been able to get it to work silently as I get an error message stating that the start time cannot be in the past event though I'm not trying to adjust the start time. The UI option to do this simply greys out the start time section.
Thank you for any help in advance,
Tyler
Hi Tyler,
You can use the BookingManager's ChangeTime method, but make sure you are not changing the time of already passed events, in this case, the start time:
The code above will attempt to reduce the end time by keeping the same start time, saving the same post-roll time. Ensure you catch any potential exception so your script will gracefully handle those situations.
I checked the code, and it can reduce the time on confirmed or active bookings (pre-roll, active time), but it will throw exceptions on other states or when the booking is close to the end time or in post-roll).
Awesome! Thanks a ton Gelber.