Date: Wed, 17 Apr 2002 10:45:26 +0200
Reply-To: Jim Groeneveld <J.Groeneveld@ITGROUPS.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Jim Groeneveld <J.Groeneveld@ITGROUPS.COM>
Subject: Re: Macro: delayed resolution ?
Content-Type: text/plain
Hi Richard,
I do not understand why you would do that, but you could experiment with
(un)quoting functions. Quote the title def in your macro and unquote
(resolve) later.
Regards - Jim.
--
Y. (Jim) Groeneveld, MSc IMRO TRAMARKO tel. +31 412 407 070
senior statist./data man. P.O. Box 1 fax. +31 412 407 080
J.Groeneveld@ITGroups.com 5350 AA BERGHEM, NL www.imrotramarko.com
My computer sometimes doesn't understand me; so do I, myself that is.
Notice of confidentiality: this e-mail may contain confidential information
intended for the addressed recipient only.
If you have received this e-mail in error please delete this e-mail and
please notify the sender so that proper delivery
can be arranged.
> -----Original Message-----
> From: Richard A. DeVenezia [SMTP:radevenz@IX.NETCOM.COM]
> Sent: Wednesday, April 17, 2002 6:12 AM
> To: SAS-L@LISTSERV.UGA.EDU
> Subject: Macro: delayed resolution ?
>
> I'm drawing a blank
>
> suppose a title is constructed as follows
>
> Diagram 1.[level].[sub-level] --- [text]
>
> I could have a macro (that uses global macro variables)
>
> %macro title1;
> title1 "Diagram 1.&level..&sublevel. --- &text.";
> %mend;
>
> and getting different titles using
> %let level=1;
> %let sublevel=1;
> %let text=foo;
> ...
> %title1;
> ...
> %let sublevel=2;
> %let text=bar;
> %title1;
> ...
>
> I am wondering is there any %let that would let me instead resolve title1,
> a macro variable, that in turn would resolve pieces of it ? (Some sort of
> delayed resolution ?)
>
> %let title1 = <something that would let me have my 'templated' title,
> without defining a macro>
>
> %let level=1;
> %let sublevel=1;
> %let text=foo;
> ...
> &title1;
> ...
> %let sublevel=2;
> %let text=bar;
> &title1;
> ...
>
> --
> Richard A. DeVenezia
> Need long HTML Titles and Footnotes ?
> http://www.devenezia.com/downloads/sas/macros/index.html#js
|