# Set minimum hour of time picker from another time picker

**URL:** <https://forum.bubble.io/t/set-minimum-hour-of-time-picker-from-another-time-picker/294816>\
**Category:** Need help\
**Created:** [November 25, 2023, 4:15pm UTC](https://forum.bubble.io/t/set-minimum-hour-of-time-picker-from-another-time-picker/294816 "2023-11-25T16:15:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ben.j](https://avatars.discourse-cdn.com/v4/letter/b/43a26b/32.png) [@ben.j](https://forum.bubble.io/u/ben.j)\
**Post date:** [November 25, 2023, 4:15pm UTC](https://forum.bubble.io/t/set-minimum-hour-of-time-picker-from-another-time-picker/294816/1 "2023-11-25T16:15:44Z")

</div>

Hi all.

This is probably a very simple solution that I’m overlooking but I’m yet to figure it out and it’s driving me crazy!

I have two date/time pickers. For a start and an end date/time.

I would like the end time to observe the following conditions:

- If the start date = end date (dd/mm/yy) then the minimum hour for the end time picker should be start time picker’s hour + 30minutes.
- If the date != the start picker’s date (dd/mm/yy) then this can be any time (12:00am - 11:30pm)

I already have the condition that the end date must be = or +24h of that of the start date.

I have tried extracting the hours from the start date/time picker but this hasn’t worked so far.

 ![Screenshot 2023-11-25 at 16.14.47](https://us1.discourse-cdn.com/bubble/original/3X/4/8/4847c2f6f4db69d16b442a8a75d1c996fa5809d5.png)  
 ![Screenshot 2023-11-25 at 16.14.19](https://us1.discourse-cdn.com/bubble/original/3X/d/c/dcafafdfdb0e1c303cf507b5bba7e95761c5611b.png)

Any help greatly appreciated!

---

<div class="post-metadata">

**Author:** ![boston85719](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/boston85719/32/77286_2.png) [@boston85719](https://forum.bubble.io/u/boston85719)\
**Post date:** [November 26, 2023, 4:43am UTC](https://forum.bubble.io/t/set-minimum-hour-of-time-picker-from-another-time-picker/294816/2 "2023-11-26T04:43:11Z")

</div>

Your minimum hour value dynamic expression looks correct…have you made sure that the Start Time Pickers Value is not empty and that the condition is being me (ie: the dates are the same).

Use the debugger and the inspect tool to check on these values from the preview page.

---

<div class="post-metadata">

**Author:** ![ben.j](https://avatars.discourse-cdn.com/v4/letter/b/43a26b/32.png) [@ben.j](https://forum.bubble.io/u/ben.j)\
**Post date:** [November 26, 2023, 9:42am UTC](https://forum.bubble.io/t/set-minimum-hour-of-time-picker-from-another-time-picker/294816/3 "2023-11-26T09:42:33Z")

</div>

Hi Boston85719,

Good idea using the debugger/inspect tool; I’m new to the platform and completely overlooked these so thank you.

It seems as though the check to evaluate whether the condition is true happens after an initial date has been set in the end date picker. Once a date has been set (which is not governed by the conditions of being \>= the start time) I can then click back in the field to set a time which is adhering to the condition.

I’ve now opted for a completely different workaround (user sets the duration instead) but thank you for the help!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/bubble/original/3X/2/8/2847faa74692c2ffa5d939d3dc3724cdd060d247.png) [@system](https://forum.bubble.io/u/system)\
**Post date:** [February 3, 2024, 4:16pm UTC](https://forum.bubble.io/t/set-minimum-hour-of-time-picker-from-another-time-picker/294816/4 "2024-02-03T16:16:25Z")

</div>

Closed on February 3, 2024, 4:16pm UTC

This topic was automatically closed after 70 days. New replies are no longer allowed.
