 |
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6
 | This is the forum to discuss the Wrox book ASP.NET 2.0 Instant Results by Imar Spaanjaars, Paul Wilton, Shawn Livermore; ISBN: 9780471749516 |
|
Welcome to the p2p.wrox.com Forums.
You are currently viewing the BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
|
|

December 19th, 2008, 02:40 AM
|
|
Registered User
|
|
Join Date: Dec 2008
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Appointment booking system
It is a useful system. However, I find some problem about the booking! For example,
After I finished to book "Conference Room 2 - West Wing" 9:00am - 10:00am (1hr) and if I want to book this same Room from 8:00am - 11:00am (3hrs), it also working! Finally, I will get two duplicate time booking, is that possible to solve this problem by change the program code? Can you help me?
|
|

December 19th, 2008, 04:50 PM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Hi there,
Looks like there's a bug in the stored procedure that checks the availability. Check out page 337 and 338 and to the very end of it, before the two closing parentheses, add this:
OR (@startDate <= StartDate AND @endDate >= EndDate)
This takes care of the case where the new appointment has a starting date/time before an existing and an ending date/time after an existing one.
I ran some quick unit tests, and it seems to work fine. Can you check if it works for you as well and let me know? Then I'll have this fix added to the errata section.
Cheers
Imar
|
|

December 21st, 2008, 11:36 PM
|
|
Registered User
|
|
Join Date: Dec 2008
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Hello Imar,
The page 337-338 only show the code but I can't find the file! I scan the check availability.aspx, AppointmentManagerDB. vb and other files but I don't know where they put! Can you show me which file?
Regards,
Eric
|
|

December 22nd, 2008, 07:21 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
It's not a code file, but a stored procedure in the database....
Imar
|
|

December 23rd, 2008, 04:39 AM
|
|
Registered User
|
|
Join Date: Dec 2008
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Thank you! It is working now! No more duplicate booking!
Eric
|
|

December 23rd, 2008, 06:35 AM
|
 |
Wrox Author
|
|
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
|
|
Great; glad it's working now.... I'll have this added to the errata section.....
Imar
|
|
 |