Organization: Office of University Computing
Newsgroups: bit.listserv.sas-l
Date:         Mon, 6 Apr 1992 13:08:58 EST
Reply-To:     "Jim S." <JSTUKAS@IRISHVMA.BITNET>
From:         "Jim S." <JSTUKAS@IRISHVMA.BITNET>
Subject:      Macro Windows

Hello Netters:
   After reading the latest SAS Observations, I was asked to write an
application for which I thought the SAS Macro windows might do quite
nicely (we don't have AF or FSP anywhere here).  Anyway, I tried to go
through the example program given in the article using the 1040EZ (which
reminds me, I've got to do my taxes).  Anyway, the program doesn't seem
to work, in that I only get two of the windows to appear (the first and the
third) on a 9121 running CMS.  However, the same program works fine under
TSO and on my NeXTstation running Mach/UNIX.
   Can someone run the program on a CMS system and tell me if it works for
them, or if there is some CMS trick I need to know about?  Actually, I
suspect that this is to call SAS and see if there is a Zap, or usage note,
but I thought I'd see what the net could come up with first.  Below I include
the program for those who don't want to type it in, and then the SAS LOG.

                                    Thanks,

                                       Jim
    Jim Stukas
    User Services                JSTUKAS@IRISHVMA (BITNET)
    University of Notre Dame     jstukas@vma.cc.nd.edu (Internet)
    (219) 239-8292               NeXT mail: stukas@mbolo.cc.nd.edu

-------------------cut here for Program----------------------------
%window welcome
   group=short
#1 @5 '** Income Tax Return for Single Filers **'
#3 @5 '  With No Dependents Form 1040EZ - 1990  '
  group=long
#1  @5 '** Income Tax Return for Single Filers **'
#3  @5 '  With No Dependents   Form 1040EZ -1990 '
#5  @2 ' 1) Enter INTEGER values.'
#7  @2 ' 2) Required information is displayed in red.'
#9  @2 ' 3) For additional information you may reference'
#10 @2 '    the Form 1040EZ booklet.'
#12 @2 ' 4) Please hit ENTER to continue.';


%display welcome.long;

%window name_add
#3  @1 'Enter your name(first,initial,last)'
#4  @1 '> ' +1 name 55 a=highlight required=yes c=red
#6  @1 'Home address(number and street).    Apt. no.'
#7  @1 '> ' +1 add1 55 a=highlight required=yes c=red
#9  @1 'City,town or post offic, state, and ZIP code'
#10 @1 '> ' +1 add2 55 a=highlight required=yes c=red
#12 @1 'Enter your social security number'
#13 @1 '> ' +1 ssn  9  a=highlight required=yes c=red
#15 @1 'Presidential Election Campaign  '
#16 @1 'Do you want $1 to go to this fund?'
   @38 'YES <' +1 pecy 1
   @47 '> NO <' +1 pecn 1
   @57 '>'  ;
%window money
#5 @1  'total wages, salaries, and tips.  This should'
#6 @1  'be shown in Box 10 of your W-2 form(s).'
   @46 '$' +1 wages 9 a=highlight required=yes c=red
#8  @1  'Enter your Federal income tax withheld from'
#9  @1  'Box 9 of your W-2 form(s).'
   @46 '$' +1 fitw  9 a=highlight required=yes c=red
#11 @1  'Taxable interest income of $400 or less.'
   @46 '$' +1 taxint  9 a=underline required=yes c=red
#13 @1  'Can your parents (or someone else) claim you'
#14 @1  'on their return? '
    @38 'YES <' +1 incy 1 a=underline c=red
    @47 '>NO <' +1 incn 1 a=underline c=yellow
   @57 '>'  ;
%let pecy=X;
%display name_add;
%let incy=X;
%display money;

-----------------------------cut again for log------------------------
11                                                          The SAS System
13:08 Monday, April 6, 1992

 NOTE: Copyright(c) 1989 by SAS Institute Inc., Cary, NC USA.
 NOTE: SAS (r) Proprietary Software Release 6.06.01
       Licensed to UNIVERSITY OF NOTRE DAME, Site 0001250003.

 NOTE: Running on IBM Model 9121 Serial Number 121496.


 STAT: VCPU 0.111051 TCPU 0.188009 (SECONDS).
 1          %window welcome
 2             group=short
 3          #1 @5 '** Income Tax Return for Single Filers **'
 4          #3 @5 '  With No Dependents Form 1040EZ - 1990  '
 5            group=long
 6          #1  @5 '** Income Tax Return for Single Filers **'
 7          #3  @5 '  With No Dependents   Form 1040EZ -1990 '
 8          #5  @2 ' 1) Enter INTEGER values.'
 9          #7  @2 ' 2) Required information is displayed in red.'
 10         #9  @2 ' 3) For additional information you may reference'
 11         #10 @2 '    the Form 1040EZ booklet.'
 12         #12 @2 ' 4) Please hit ENTER to continue.';
 13
 14
 15         %display welcome.long;
 16
 17         %window name_add
 18         #3  @1 'Enter your name(first,initial,last)'
 19         #4  @1 '> ' +1 name 55 a=highlight required=yes c=red
 20         #6  @1 'Home address(number and street).    Apt. no.'
 21         #7  @1 '> ' +1 add1 55 a=highlight required=yes c=red
 22         #9  @1 'City,town or post offic, state, and ZIP code'
 23         #10 @1 '> ' +1 add2 55 a=highlight required=yes c=red
 24         #12 @1 'Enter your social security number'
 25         #13 @1 '> ' +1 ssn  9  a=highlight required=yes c=red
 26         #15 @1 'Presidential Election Campaign  '
 27         #16 @1 'Do you want $1 to go to this fund?'
 28            @38 'YES <' +1 pecy 1
 29            @47 '> NO <' +1 pecn 1
 30            @57 '>'  ;
 ERROR: Unable to open window macro file NAME_ADD.
+ERROR: Unable to open window macro file NAME_ADD.
+ERROR: Unable to open window macro file NAME_ADD.
 31         %window money
 32         #5 @1  'total wages, salaries, and tips.  This should'
 33         #6 @1  'be shown in Box 10 of your W-2 form(s).'
 34            @46 '$' +1 wages 9 a=highlight required=yes c=red
 35         #8  @1  'Enter your Federal income tax withheld from'
 36         #9  @1  'Box 9 of your W-2 form(s).'
 37            @46 '$' +1 fitw  9 a=highlight required=yes c=red
 38         #11 @1  'Taxable interest income of $400 or less.'
 39            @46 '$' +1 taxint  9 a=underline required=yes c=red
 40         #13 @1  'Can your parents (or someone else) claim you'
 41         #14 @1  'on their return? '
 42             @38 'YES <' +1 incy 1 a=underline c=red
 43             @47 '>NO <' +1 incn 1 a=underline c=yellow
 44            @57 '>'  ;
 45         %let pecy=X;
 46         %display name_add;
 ERROR: Unable to open window macro file NAME_ADD.
+ERROR: Unable to open window macro file NAME_ADD.
+ERROR: Unable to open window macro file NAME_ADD.
 47         %let incy=X;
 48         %display money;
12                                                          The SAS System
13:08 Monday, April 6, 1992

 ERROR: Errors printed on page 1.
+ERROR: Errors printed on page 1.
+ERROR: Errors printed on page 1.

 STAT: VCPU 0.359763 TCPU 0.530824 (SECONDS).
 NOTE: SAS Institute Inc., SAS Circle, PO Box 8000, Cary, NC 27512-8000