Dear Power Apps Community,
I have this basic form control connected to SP list to book a pool car.

I want to verify my source SP list column availability: if, for the selected Number Plate and Start Date Time & End Date Time also within the time range, a booking exists, notify the user that the booking already exists else submit the form.
Reserve button onSelect property:
If(
Not(
IsBlank(
LookUp(
'SID Pool Car Reservation',
'Availability '.Value = "Free" And 'Number Plate'.Value = DataCardValue10.Selected.Value And 'Start Date' = DateValue1.SelectedDate + Time(
Value(HourValue1.Selected.Value),
Value(MinuteValue1.Selected.Value),
0
) And 'End Date' <= DateValue2.SelectedDate + Time(
Value(HourValue2.Selected.Value),
Value(MinuteValue2.Selected.Value),
0
)
)
)
),
SubmitForm(EditForm2),
Not(
IsBlank(
LookUp(
'SID Pool Car Reservation',
'Availability '.Value = "Booked" And 'Number Plate'.Value = DataCardValue10.Selected.Value And 'Start Date' = DateValue1.SelectedDate + Time(
Value(HourValue1.Selected.Value),
Value(MinuteValue1.Selected.Value),
0
) And 'End Date' > DateValue1.SelectedDate + Time(
Value(HourValue1.Selected.Value),
Value(MinuteValue1.Selected.Value),
0
) And 'End Date' <= DateValue2.SelectedDate + Time(
Value(HourValue2.Selected.Value),
Value(MinuteValue2.Selected.Value),
0
)
)
)
),
Notify("A reservation already exists for the selected pool car and for the selected dates."),
SubmitForm(EditForm2)
)
This formula is not working as expected, could you help me where am I doing wrong?
Thanks.