I would like to do what it says in the title of this thread but can´t find a way to do it. Any solutions?
The issue is that your SAS session does not "start in" the folder of the sas program you double-click but (iirc) in the windows\system32 folder.
Verify this by examining the status bar (very bottom of sas window) when you open a program with double-click.
If you wish to continue working this (diuble-click) way there are few options available.
1
place a copy of your autoexec.sas in that windows\system32 folder
Or 2
Create a windows environment variable called sas_options holding value
-initcmd "listing off"
Or 3
Update the installed SAS config file by adding (near the top)
-initcmd "listing off"
(backup that file before changing it)
Since I spend most of my time on SAS programming I always have a SAS session open. To review another program I just drag it to SAS, so I don't need these methods.
Good luck
peter
Hi,
How about the following:
7298 - How to close the Output window by using a display manager (dm) command
Regards,
Amir.
Thank you Amir, that works great for removing the output window but unfortunately not permanently, When I start SAS again after closing the output window comes back again.
Add the statement
Dm 'listing off';
to an autoexec.sas file in the folder where you start SAS
Then your sas sessiin will start without that output window
Good luck
peterC
Thank you Peter!
This would have solved my problem completely if it wasn´t for one tiny detail. When I open SAS by clicking on a SAS-file the output window appears like before.
Otherwise it is gone like you said it would be. I created a file named autoexec.sas (that file didn´t previously exist) in my "current folder" and pasted the code you provided.
Thanks again!
The issue is that your SAS session does not "start in" the folder of the sas program you double-click but (iirc) in the windows\system32 folder.
Verify this by examining the status bar (very bottom of sas window) when you open a program with double-click.
If you wish to continue working this (diuble-click) way there are few options available.
1
place a copy of your autoexec.sas in that windows\system32 folder
Or 2
Create a windows environment variable called sas_options holding value
-initcmd "listing off"
Or 3
Update the installed SAS config file by adding (near the top)
-initcmd "listing off"
(backup that file before changing it)
Since I spend most of my time on SAS programming I always have a SAS session open. To review another program I just drag it to SAS, so I don't need these methods.
Good luck
peter
I can't validate this at present but if you have some control over your desktop (its not completely locked down) go th Control Panel - Default Programs and find the entry for .sas files. It should specify sas.exe with some additinal parameters. You can add -initcmd "listing off" to the parameters after sas.exe
Richard.
Thanks a lot! I tried what I thought would be the easiest solution and added the autoexec-file to my system32 folder and it worked!
Adding a sasv9.cfg file to that folder allows you to add "invocation-only" options
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.