Current menu script

Jeff Harrison jeffaharrison at yahoo.com
Fri Feb 3 14:24:44 PST 2006


FYI, for those of you that may have been interested in
the routine I was developing that logs when a menu
script is run - Here is my "final" version.  It logs
the Date, time, user ID, menu script, menu heading,
and menu choice (item chosen on the menu).

It can be called by adding the following line to each
menu script where you wish to implement logging:

$PFPROG/fp/dclerk lib -s1 -z logger -rw $0

The lib/prc.logger process is as follows:

:'prc.logger  Jeff Harrison  02/01/06::
:'  Log info on menu access::
@menu:::
::gosub getmenu:
::lookup acc = accesslog r=free -e:
::acc(1)=@id     ' who:
::acc(2)=@td     ' date (when):
::acc(3)=@tm     ' time (when):
::acc(4)=mid(ac,"2","34")      ' menu heading (what):
::acc(5)=@pw     ' menu item being run (what):
::zz=len(@pw):
::acc(6)=mid(@pw,zz,"1")   ' menu option chosen:
::write acc:
fini:::
::exit:
getmenu:::
:not @pw co ".":return:
::mn=mid(@pw,"1",instr(@pw,".","2")-"1"):
::aa=open(mn{"","rt"):
:aa lt "0":exit:
::ab=readline(aa,ac):
::return:
::aa(8,.0); ab(6,.0); ac(60); mn(30):
::zz(3,.0):

---
Jeff Harrison
jeffaharrison at yahoo.com

Author of JHExport and JHImport.  The easiest and
fastest ways to generate code for filePro exports and imports.

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


More information about the Filepro-list mailing list