Hello everyone. I need some help with understanding the masking of specific characters being passed into Macro's. This is actually related to a problem that Tom helped me solve the other day, however it has arisen in a seperate problem (I will use the first for simplicity). Okay, the following code does not work. the reason is the FIRST macro input has a "(" within the name, so when sas Reads the macro (in the call step) it is reading an open parenthesis, and it is thus assuming macro variable 1 and 2 are the same (since it does not find a closed parenthesis). %macro Mapping_Names(dsin,dsout); data &dsout.; infile "&dsin." dsd lrecl=32000 truncover obs=1; length varnumCSV 8 name $2000.; input @; do varnumCSV = 1 to countw(_infile_,',','Q'); input name @; output; end; run; %mend Mapping_names; %Mapping_Names(tab verification(((Greengiant Population, outputdata); So basically I want to pass the entire first string (up until the comma) as a single string into sas, and I would like it to ignore the ((( values after the word Verification. This is because someone is naming files with these values (I can't change this). I also have written macro's that will open Excel files and then run the associated VBA within the Excel files (like the following) and someone named an excel with with a "(" in its title so I ran into the same error. %macro runexcel_example(excelfile,macroname); FILENAME xcel DDE "EXCEL|SYSTEM"; data _null_; file xcel; put "[open(""&excelfile."")]"; put "[open(""¯oname."")]"; put "[quit()]"; run; %mend runexceL_example; %runexcel_Example(I:\projects\multi(files.xlsm , multi(files.xlsm!Multifiles.multifiles); Note that this macro program works for every macro we have, except for when the names have special characters (namly these parenthesis). Is there a way to hide these values and have sas put them directly into the file so it doesn't combine both macro varaibles into 1 variable and blow up the program? I am thinking something along the lines of the %str, or %nstr, or %quote values but I have not been able to figure this one out! Thanks! Brandon ¯ovariable."")]";
... View more