Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Booking

Status
Not open for further replies.

Spikemannen

Instructor
Feb 22, 2005
58
0
0
SE
Hi!

I'm going nuts over here.
I have a table with Objects.

tblObjects
ObjectID (calc)
Object_name (text)
Avaible_from (date)
Avaible_to (date)

etc...

And I have a table for booking.

tblBooking
BookingID (calc)
Name (text)
Phone (text)
Object (relation to tblObjects)
Book_from (date)
Book_to (date)

etc...

Now, I should only be able to book the specific object between tblObjects.Avaible_from.value to tblObjects.Avaible_to.value.
And when I have made a booking for an object, ofcourse I should not be able to book the same dates for another person (tblBooking.Name.value).

How will I do?

Please, help me...

Best Regardz,

Spikemannen
 
Hi. What's not working? What have you tried so far?

So are you doing this on a form? How is it set up? You are BOOKING an object...are you picking the object from a combo box or something? Based on dates?

Please clarify your process, provide some sample data and expected outcome. Thanks!

Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Okey here goes...

I have this two tables:

tblObject:

ObjectID (calc)
ObjectName (text)
Avaible_from (date)
Avaible_to (date)
Price (currency)

and

tblBooking:

BookID (calc)
Booker (text)
Phone (text)
Cell (text)
Payment (text) cbo
CardNr (text)
Object (relation to tblObjects) cbo
From (date)
To (date)
Cost (currency)

tblObject and tblBooking is both forms (frmObject and frmBooking)

So in frmObject I choose in avFrom from when the object is "bookable" and to when in avTo.
Then in frmBooking I should be forced to choose between these two dates in tblBooking.From and tblBooking.To when I choose the object.
And when I register the second booker in that object I should not be able too book any date between the first bookers tblBooking.From.Value to tblBooking.To.Value.

How to do?

I have tried a kind of lookup code but I did not get that to work. :-(


Best Regardz,

Spikemannen
 
Thank you, but - my english is not that good, I have to admit that it is a bit over my head.

Best Regardz,

Spikemannen
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top