Date: Fri, 12 Mar 1999 08:33:51 +0100
Reply-To: Albert Bonillo <MacrosSPSS@METODO.UAB.ES>
Sender: "SPSSX(r) Discussion" <SPSSX-L@UGA.CC.UGA.EDU>
From: Albert Bonillo <MacrosSPSS@METODO.UAB.ES>
Subject: Re: Macros and files
Content-Type: text/plain; charset="iso-8859-1"
I think that the error is caused in the DATA LIST and in the SAVE
instruccions. Is necessary that the name of the file appers in inverted
commas, like this: 'I:\GROUND...' and 'Pickup.sav'. Now, you are concating
the name with inverted commas, but this only serves for concatenating the
name and not for include the parameter, !A, in inverted commas.
If you use the function !QUOTE, like this:
DATA LIST FILE =!QUOTE(!A) ....
and
SAVE OUTFILE =!QUOTE(!CONCAT('PickUp',!I,'.sav)).
this macro run perfectly.
Regards.
-----------------------------------------------------
Albert Bonillo Martmn
Laboratori d'Estadmstica Aplicada
Universitat Autrnoma de Barcelona
-----------------------------------------------------
-----Mensaje original-----
De: Patricia Neri <p.neri@AIR.UPS.COM>
Fecha: jueves, 11 de marzo de 1999 16:10
Asunto: Macros and files
>I am trying to write the following macro, but it seems that the
>specification of the files is not working well. Thanks to any suggestions
>you all may have:
>DEFINE prep1 (P=!CMDEND).
>!DO !i !IN (!P).
> !LET !A =!CONCAT('I:\GROUND\Volume\CTR',!i,'byslicpudelrpt.txt') .
> SET
> BLANKS=0
> UNDEFINED=WARN.
> DATA LIST
> FILE=!A FIXED RECORDS=1 TABLE /1 p_d 1-1 (A) vol 3-11 us 15-16(A)
center
>18-2 1(A) .
> EXECUTE.
>SAVE OUTFILE=!CONCAT('PickUp',!i,'.sav')
>/COMPRESSED.
>
>!DOEND.
>!ENDDEFINE.
>
>
>prep1 p = 02.
>
>>Warning # 206 in column 19. Text: \
>>An invalid character has been found on a command.
|