home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
assemblr
/
library
/
cmdline
/
switch
/
switch.msg
< prev
Wrap
Internet Message Format
|
1988-09-24
|
1KB
From: cgs@umd5.umd.edu (Chris Sylvain)
Newsgroups: comp.binaries.ibm.pc
Subject: switch, demonstrates how to read command line switches
Date: 24 Sep 88 11:01:04 GMT
Summary: switch.arc, demonstrates how to read command line switches
Approved: dhesi@bsu-cs.UUCP
SWITCH demonstrates one way to read single-letter switches from the
command line. The command line switches are received by the program
from the program segment prefix (PSP) beginning at offset 80h. The
executable and assembly source are supplied.
The program uses a single memory word (one bit per switch) to store
information for 16 switches, assumed to be /A through /P. All switches
are treated as toggles. The code commenting, wording of printing
messages and some of the code itself have been changed in a number of
places.
This is one of three programs, being posted consecutively to this
newsgroup, that was written using MASM 5.0 by Hardin Brothers for the
April 1988 issue of PC Resource magazine, (C) Copyright 1988 by IDG
Communications/Peterborough, Inc.
Hardin Brothers is a freelance programmer and technical writer. Write
to him at 280 N. Campus Ave., Upland, CA 91786. Enclose a self-
addressed, stamped envelope for a reply.