:LASTCMD, Utilities, Grab and Display Last Terminal CommandGLASTCMD V1.01-002 [3-JUN-1995] - Grab and Display Last Terminal Command7Copyright © 1994, Chris Olive & Siemens Medical Systems.Written by Chris Olive 0LASTCMD - Grab and Display Last Terminal Command;(c) Copyright 1994, Chris Olive and Siemens Medical SystemsN------------------------------------------------------------------------------NLASTCMD allows a suitably privileged user (one with CMKRNL) peek at theNtypeahead buffer of another terminal. This allows one to grab another's lastNcommand no matter in what environment the target user may be. As long as theNenvironment utilizes the terminal's typeahead buffer (usually viaNLIB$GETINPUT), LASTCMD will display that command. Utilities using SMG do notNuse the typeahead buffer and there are a few other exceptions. (In theseNcases, LASTCMD will still report the last command in the typeahead buffer;Nthat command just may not be the very, very thing the user is doing at theNmoment). But overall, LASTCMD will grab the last command typed by anotherNuser and display it. Use LASTCMD in place of Hunter Goatley's GETCMD utilityAwhen the target user is not in the DCL environment at the moment. Syntax: LASTCMD NUnfortunately, LASTCMD will not support RT devices since the internal dataHstructure LASTCMD uses (UCB -> TTYTA) is not inherit with the RT device.NLASTCMD utilitizes kernel mode code, so maintain the caution one should alwaysNmaintain when using CMKRNL utilities. It has been tested and is believed toNwork okay. However, neither I nor my employer can be or will be heldNresponsible for any damages which result from the use or misuse of LASTCMD.NUse of LASTCMD implies that you understand all that. Other than that, havefun!O_______________________________________________________________________________& ___ ___ ___ _ _ ___ _ _ ___M /___ | |__ |\ /| |__ |\ | /___ Chris Olive, VMS Systems ConsultantL ___/ _|_ |___ | Y | |___ | \| ___/ Internet: olive@sgi.siemens.comC Medical Systems, Inc. Voice: 708.304.7793C 2501 N. Barrington Road. FAX: 708.304.7704A Hoffman Estates, IL 60195 CompuServe: 73740,1636O_______________________________________________________________________________