Tcl API Reference -- ns_atshutdown

### ns_atshutdown

#### Overview

Register a script to be run at server shutdown

#### Syntax

ns_atshutdown {script | procname ?args?}

#### Description

ns_atshutdown registers a Tcl script or procedure to be run when the virtual server shuts down.

#### Example

        proc theLastThing {} {
        	global Shared
        	close $Shared(file)
        	ns_mutex destroy $Shared(lock)
        }

        ...
        ns_atshutdown theLastThing
        ...

Top of Page
Copyright © 1998-99 America Online, Inc.