Re: Open Text File, Menus

Neal S. Pressman ex 2317 (nsp83273@cae091.ed.ray.com)
Tue, 28 Jan 97 11:24:00 EST

-> The second problem is reading in a text file, currently I'm fliping
-> through the provided help stack one card at a time (if there is a search
-> function please let me know!) and trying to get info but to no avail. I
-> can get as far as getting the location of the "filename" but cannot for
-> the life of me read in its contents into a variable or into a field.
->
-> If anyone can send me a small example of each I think I'll be able to
-> manage the rest.
->
-> Thanks in advance.
i think the proper way is to use "open" commands in order to keep things
portable. i have opted to use the capabilites of UNIX as i have no
intention of porting to other platforms. hope this helps......

to create a dynamic pull down:

on openCard
put shell("cat serverlist") into menu "Servers"
end openCard

to put information into a field:

put shell("echo $FINLOC | sed -e 's/\/_db$//'") \
into field "FINAL_LOCATION"

to put information into a variable:

put shell("check_prec.csh $TO") into PRECSTAT

i dont know if these are the best ways of doing things but they have
been very effective for me.
\\|//
(0~0)
----------------------------oooO-(_)-Oooo----------------------------
Neal S. Pressman Raytheon Electronic Systems
System Administrator (MCAE) 528 Boston Post Road
phone: (508) 440-2317 Sudbury, MA 01776
fax: (508) 440-2684 ms 4-1-283
E-mail: nsp@cae091.ed.ray.com
____________________________________Oooo.____________________________
.oooO (___)
-------------------------------------------------------------------
Contrary to popular belief, Unix is user friendly. It just happens
to be very selective about who it decides to make friends with.
-------------------------------------------------------------------