Okay, here's the new and improved version. This should eliminate the
use of outside files. All files are created within the command file and
purged at the end.
purge netcheck > $null
purge netchk0 > $null
purge netsort,temp > $null
build netcheck;rec=-80,,f,ascii
build netsort;temp;rec=-80,,f,ascii
file sortnet=netsort;acc=append
echo i netcheck >*sortnet
echo o netchk0 >*sortnet
echo k 57,21 >*sortnet
echo end >*sortnet
file netx=netcheck,old
listf ci.pub.sys,8 >*netx
sort < netsort >$null
purge netcheck >$null
setvar cntr 0
echo ![chr(27)]H ![chr(27)]J
echo Session User Name.Account Ldev / IP
echo ------- -------------------------- ------------------
while setvar(cntr,cntr+1) < finfo("netchk0",19)
print netchk0;start=!cntr;end=!cntr > rec1
input rec2 < rec1
if pos("#S","!rec2")>0
setvar info_str str("!rec2",1,35) + str("!rec2",63,17)
echo !info_str
endif
endwhile
reset netx
reset sortnet
purge netchk0
deletevar cntr
--
Larry Barnes
Director of I.T.
Mitek Corp.
602-438-4545 X 1366
Phoenix, AZ 85040
Check Us Out !
http://www.mitekcorp.com
http://www.atlassound.com
http://www.coustic.com
http://www.mtxaudio.com
http://www.xtant.com
http://www.dcmspeakers.com
|