Re: SYS$FAO coding example in BLISS-32

Liste des GroupesRevenir à co vms 
Sujet : Re: SYS$FAO coding example in BLISS-32
De : goathunter (at) *nospam* goatley.com (Hunter Goatley)
Groupes : comp.os.vms
Date : 12. Jul 2024, 04:30:18
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <bdfeaf6e-f242-41b9-9e28-bb597e2dad7c@goatley.com>
References : 1
User-Agent : Mozilla Thunderbird Beta
On 7/11/2024 9:55 AM, David Meyer wrote:
(I posted about this on the VSI forums, but am posting here in case
there are any old VMS hackers hanging out only here.)
 Does anyone have an code example of calling SYS$FAO in a BLISS program?
 I'm trying to teach myself the language from old manuals and want a way
to print text and numeric data from programs to my terminal. I've found
the TUTIO package, but would like to know a method that also works in
batch mode. SYS$FAO looks like a useful way to format data into
character strings for output with LIB$PUT_OUTPUT, but I've so far only
succeeded in printing blank lines, and can only find coding examples in
MACRO or FORTRAN.
 
You might take a look at my FREE utility, which displays disk block usage summaries for mounted disks.
https://vms.process.com/scripts/fileserv/fileserv.com?FREE
It's written in BLISS and calls SYS$FAO (via the $FAO macro). It also shows how to call $DEVICE_SCAN, LIB$PUT_OUTPUT, and $GETDVIW. It's a much smaller program than my other BLISS packages that call it. This isn't going to wrap correctly, but here's some sample output.
DECUServe$ run free
Device Name      Volume Label   Type      Used Blocks     Free Blocks    Total
---------------- -------------- ------ --------------- --------------- ---------
DSA0:            ALPHASYS       DKX00   15325103 (79%)   4206033 (21%) 19531136
DSA1:            USER1          DKX00    3920423 (21%)  15610713 (79%) 19531136
DSA2:            USER2          DKX00   11194730 (58%)   8336406 (42%) 19531136
[...]
Totals:               13 mounted disks  328010MB (77%)  101353MB (23%) 429363MB
Hunter
------
Hunter Goatley, Process Software, https://www.process.com/
goathunter@goatley.com  https://hunter.goatley.com/

Date Sujet#  Auteur
11 Jul 24 * SYS$FAO coding example in BLISS-326David Meyer
11 Jul 24 +* Re: SYS$FAO coding example in BLISS-324Jim Duff
12 Jul 24 i`* Re: SYS$FAO coding example in BLISS-323David Meyer
12 Jul 24 i +- Re: SYS$FAO coding example in BLISS-321David Meyer
12 Jul 24 i `- Re: SYS$FAO coding example in BLISS-321Hunter Goatley
12 Jul 24 `- Re: SYS$FAO coding example in BLISS-321Hunter Goatley

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal