Click to See Complete Forum and Search --> : Scheduling Software in ASP using Access


Pestilence
09-27-2001, 10:43 AM
I've been trying to write some scheduling software for the place I work for (a microscopy lab) and I've gotten bogged down in adding appointment times. I'm not exactly sure what code I would need for this. I know handling dates is tricky.

What I have so far in pseudocode is that I have to check whether the appointment that a person is trying to schedule right now envelops a pre-existing appointment (starts before the existing starting time and ends after the existing ending time of an appointment), or whether that appointment is completely enveloped by the already existing appointment, or the starting time for the intended appointment is before the existing appointment, however, the ending time is after the after the existing starting time of the appointment, and whether the starting time of the intended appointment is before the ending time of the pre-existing appointment, but the ending time is ok. And I know I need to check for all the appointments that day so I need to loop through this until I've gone through all the appointments for that day.

I don't know if I'm going about this the right way and even if I am, I'd appreciate it if I could get a little coding help as this is kinda over my head, although I didn't think so at the time. http://www.sharkyforums.com/ubb/tongue.gif

------------------
(\__/) See the bunny.
(='.'=) Hear the bunny.
(") (") Pet the bunny.

BE the bunny.

namgor
09-27-2001, 11:03 AM
If you get to put the code in the server, then you can simply use MS task scheduler!

------------------
DHAHL3seasons GP:73 G:121 A:55 Pts:176 GWG:12 +/-:184
UWSWA1season GP:9 G:12 A:8 Pts:20 GWG:3 +/-:-3
MCBHL1season GP:4 G:5 A:5 Pts:10 GWG:0 +/-:9

uwcdc.com (http://www.uwcdc.com) or namgor.com (http://www.namgor.com)

Pestilence
09-27-2001, 11:11 AM
Microsoft Task Scheduler? I don't think you can schedule appointments from the web with it. Please do tell me if I'm wrong and point in the appropriate direction to learn more about this if possible.

------------------
(\__/) See the bunny.
(='.'=) Hear the bunny.
(") (") Pet the bunny.

BE the bunny.

namgor
09-27-2001, 12:04 PM
ic... so you want the client to schedule their own tasks... hm... actually i have never use scheduler before http://www.sharkyforums.com/ubb/smile.gif

But where does it store the appointments? a file -- can you append / edit that file using asp ?

------------------
DHAHL3seasons GP:73 G:121 A:55 Pts:176 GWG:12 +/-:184
UWSWA1season GP:9 G:12 A:8 Pts:20 GWG:3 +/-:-3
MCBHL1season GP:4 G:5 A:5 Pts:10 GWG:0 +/-:9

uwcdc.com (http://www.uwcdc.com) or namgor.com (http://www.namgor.com)

Pestilence
09-27-2001, 12:51 PM
Originally posted by namgor:
ic... so you want the client to schedule their own tasks... hm... actually i have never use scheduler before http://www.sharkyforums.com/ubb/smile.gif

But where does it store the appointments? a file -- can you append / edit that file using asp ?


Yeah, the whole point of this is to get them to do the work. http://www.sharkyforums.com/ubb/tongue.gif It stores the appointments in an access database under the table appointments.

------------------
(\__/) See the bunny.
(='.'=) Hear the bunny.
(") (") Pet the bunny.

BE the bunny.

Grizzly
09-27-2001, 01:33 PM
Ah I know what you're getting at. I once wrote a reservation system for an online apartment rental database. I built a search engine for it so you could search for available apartments by a date range, and if an apartment had an opening in that date range, it would be returning from the search.

So I think I had a SQL statement in there which should be relatively similiar to what you're getting at.

A simplified version of my SQL statement is something along the lines of:


SELECT *
FROM apartments
WHERE Start_Date >= '$Search_End'
OR Start_End <= '$Search_Start'


You should be able to apply this same sort of logic in your situation.

Pestilence
09-27-2001, 05:14 PM
SELECT * FROM apartments WHERE Start_Date >= '$Search_End' OR Start_End <= '$Search_Start'

Is the dollar sign and the single the manner in which all dates are delimited? I know dates are a pain in the arse.

Also, how exactly do I compare times using the short time format (10:00 AM)? I'm using that format for my time in my access database.

------------------
(\__/) See the bunny.
(='.'=) Hear the bunny.
(") (") Pet the bunny.
BE the bunny.

[This message has been edited by Pestilence (edited September 27, 2001).]

Grizzly
09-28-2001, 12:25 AM
No the $ symbols are because I was thinking in "PHP" terms, you can code in whatever language you wish.

And what exactly do you mean by "Short Time Format"

I've worked with Date/Time fields in Access before, and you can make relational SQL statements on them just fine.

Pestilence
10-01-2001, 11:08 PM
My apologies, it's actually medium time format. Medium time format consists of hh:mm PM (i.e. 4:05 PM). I got a tip from a friend about how to use dates in some asp pages from access. I'll try it tommorrow and let you all know.

------------------
(\__/) See the bunny.
(='.'=) Hear the bunny.
(") (") Pet the bunny.

BE the bunny.