|
Hi Rob,
In that case I would try one of the other macro QUOTing functions
(around a macro variable specification), e.g. %NRQUOTE, %NRBQUOTE.
I am not sure which one, that would need studying the docs and some
experimenting and that is what you can do yourself as well.
Good luck and come back telling us _how_ you succeeded.
Regards - Jim.
--
Jim Groeneveld, Netherlands
Statistician, SAS consultant
home.hccnet.nl/jim.groeneveld
On Tue, 11 Apr 2006 03:07:56 -0700, ra <rob.ashmore@MBF.COM.AU> wrote:
>Thanks Jim,
>
>Yes I agree that would help in this instance.
>
>Unfortunately, in the bigger scheme of things, the parameters to the
>macro are derived and supplied externally by code which calls this
>macro. I guess I could write something which
>transforms any single '(' into the string you suggested.
>
>However, I was hoping to find something that could be used within the x
>macro to deal with the situation. Perhaps this is not possible?
>
>cheers,
>
>
>rob.
>
>
>
>
>Jim Groeneveld wrote:
>> Yes Rob,
>>
>> %x (code=abc%STR(%()123, name=jim); * (I feel addressed [%STR(;)-);
>>
>> Thus change the ( into %STR(%() . The %STR function inhibits resolution
and
>> inside the argument list between ( and ) the literal ( has to be escaped
by
>> a % character.
>>
>> Regards - Jim.
>> --
>> Jim Groeneveld, Netherlands
>> Statistician, SAS consultant
>> home.hccnet.nl/jim.groeneveld
>>
>>
>> On Tue, 11 Apr 2006 01:12:22 -0700, ra <rob.ashmore@MBF.COM.AU> wrote:
>>
>> >I want to invoke a macro where one of the macro parameters
>> >contains an 'open' parentheses but no 'close' parentheses.
>> >
>> >When I run the below code (as an example) the only thing that
>> >appears in the sas log is a message saying that the macro is beginning
>> >execution.
>> >
>> > %macro x (code=,name= );
>> > %put >>>>>>>>>>>> &code ;
>> > %mend x;
>> >
>> >%x (code=abc(123 ,name=jim );
>> >
>> >
>> >
>> >Is there some technique I can use to ensure that the
>> >open parentheses '(' is just treated as normal text?
>> >
>> >regards,
>> >
>> >
>> >rob.
|