manipulating table data in datasheet view

  • Thread starter Thread starter roger
  • Start date Start date
R

roger

Hello Friends;

I have this program which is like a program used for these
manufacturing workers training program. What happens is
that the students start the session in which they go thru
a course in like machinery,electronics etc and they are
basically not supervised or anything...it is like
computerised training. Now, some students cheat in the
sense that they login at 9AM and are supposed to be on for
1 hour ...so they must finish at 10 AM but what they do is
login at 9Am and then go out of the room and then do not
come back till late or sometimes forget about it. For
these students I want to have apenalty something like

If logout time -login time >2 hrs then the
time counted =1 hour only.

This will serve as a penalty for them in the future.

The only problem is that I have to do this process in the
datasheet view of the table. What I want is let the system
calculate the times and then only when the Supervisor
clicks the time for the penalty button the code will run
and will update the data in the datasheet view.

How would I do this?
 
The only problem is that I have to do this process in the
datasheet view of the table.

As far as I know, there's no way to do this. Table datasheets have no
programmable events. Any chance you could use a Form (perhaps a Form
in datahsheet view)?
 
Hello John:

Can I then use like an update query on this table to
update records where the logout time -logintime is greater
than 2 hours?

Certainly. Just put in a calculated field:

TimeLoggedIn: DateDiff("h", [logintime], [logout time])

and use a criterion of >= 2 on it.
 
Back
Top