Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
Hello all,
I am a network admin at my local library and have been requested to have the public computers automatically log off after 60 min to avoid useage abuse. I have posted this question to the NT forum and have gotten no responses, so I take it that it is not just readily available in NT. I was thinking that I could write a batch program that would start when the user logged on and started a timer, maybe at like 55min it would display a message stating that it will log off in 5 min and then automatically log off at the designated 60 min.To be honest I have only written a few programs, and am not very confident on how to do it or how to get it to start up when the user logs in. Could anybody help me with this, or if someone wanted to make some extra money, the library would be willing to pay someone to write it, maybe in C or C++ or basic, i dunno??
I will be looking forward to hearing from you all.

"I am a network admin at my local library..."
-Most real admins would find that offensive, especially since you talk as though you've never administered a network...However, just so that I don't seem like a total jerk...
If you're running any sort of administration software (such as Novell) or have a Unix gateway, you could easily force them to logoff (I assume... I don't have much experience with Novell); just google it ;p.
Otherwise, you could always try looking on google for an already-made program (the one I linked to is for shutting down the computer, but that's probably better, since anyone who logs off could simply just immediately log back on...)
If you're intent on having them log off, you could easily write a program in C to run in the background (just use system("logoff") to log them off - don't have NT to test it on, but the "logoff" command works on XP, so, again, I'm assuming). If you're unable to find anything, and can't write it yourself, just reply to this message and I'll see if I can find the time to write one...btw the easiest way to get a program to startup when the user logs on is to add a shortcut under start | programs | startup.

"However, just so that I don't seem like a total jerk..."
Network Admin's are not required to know that much about programming. And programmers are not suppose to know that much about Subnetting or networking standards or account administration. I do not feel that my post should offend network admins.
However, just so that I don't seem like a total jerk...
The library is a very small network, there is no Novell Server or Unix server, nor the budget or need to implement one. Yes I have configured that sort of thing on Novell before. I did a google search before I posted on here and did not find a very good program that did exactly what I am looking for.
The public does not have the login name or password, the library staff log them on. So there is not a problem with them just logging back on. These are dinosaur computers due to low funding, shutting the computers down is not an option because the library staff doesn't want to have to wait for it to boot up in between every use. The program you suggested, in effect does exactly what I want, except it shuts the computer down and not logs them out.
I did already know how to add programs to the start up menu, so I don't know why I asked about that(just searching for a more complete answer I guess)
I am not a good programmer but I will look into a C type program.
Any other suggestions???

What OS do the computers use? Hopefully one runnin on the NT-shell.
there is a way to have a batch file basically do a countdown. i remember someone asking how to do it on this forum before but you'd have to search it up a little. but once the countdown got to 60 minutes or 3600 seconds or whatever then you could have it execute a batch file that consists of: shutdown -l
that would log the person off immediately. of course, everytime i've tried it on myself i tried shutdown -l -f -t 3600 but that logged me off immediately and didn't ask if i wanted to save anything from the programs i was running etc. hence the reason this is the 3rd time i'm writing this to you. lol *stupid me* but yea, the shutdown.exe file comes in every install of XP so you would just have to copy it from there and put it in the system32 file of the computer you want it to run on. as far as i know this is only for the NT-shell but you could google about the shutdown command on older OS's. about the whole "warning message" thing i'm not sure how you'd go about that, but its doable somehow.. if you found a little program that would give a pop up message then you could have your batch file that executes the log off execute that file too.

Hey,
Yeah there are 5 public computers that need that. they are all running NT4 with all the latest service packs and such. The warning message would be optional, the main thing is to have it log off after the 60 min. It sounds like the shutdown command is what I am looking for, I just need to find the code for the timer and I maybe in business.Thank you for your help

Hey,
no problem, thats what i'm here for. but i also remembered that this website called rjlsoftware.com has a shutdown program also. since i wasn't sure of the compatability of the shutdown.exe that windows has out, rjlsoftware also has a shutdown program: http://www.rjlsoftware.com/software/utility/shutdown/
and all of their programs are free. so you might also be able to find something on there that would be like a timer. i've been trying to write a program that would do it for you but i dont know how to execute it in the background..

Hey,
That Shutdown.exe command from that link you provided is exactly what I am looking for with the 2 option. What language are you trying to write it in? It does not have to be completely in the background, as long as the users couldn't modify it or stop it in anyway. Let me know what ya come up with,Thanks

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |