01-10-2017 06:50 AM
In my SAS EG Program Editor window code automatically erased withou any human action, But in log window my code is available and in the Results Window output is displaying. Please let me know how can I import log into the Program Editor window.
01-10-2017 06:54 AM
Select (mouse) the desired lines and copy/paste to the program editor. Use the Alt key while mouse-selecting only the columns with the line numbers, and delete them. Then you have to remove the NOTEs and page headers manually.
01-10-2017 08:41 AM
If you have 'full' SAS not UE, EE, EG or SAS Studio and the old text editor you can use this SAS code below.
This macro will copy the log to the program editor.
home;log;find ' ';mark;bot;mark;store;home;pgm;1;paste;
Hit a function key, mouse action or type getlog on any 'clean' command line.
You can put the script on a function key, mouse action, without the macro wrapper, or put the macro
in your autocall folder. You never need to migate this code when you install a new version of SAS and
it has worked since the late 70s, so you .
Note the issue is that SAS disabled the store command in all editors except the 'old' text editor.
I beleve it used to work in the EE editor but was later disabled.
All of SAS can be executed from the 'old' text editor command line.
I even execute Python scripts from the command line.
01-10-2017 11:30 AM
I won't add any new solution but you mentioned EG and the fact that the "code automaticall erased".
The behavior you report is the one available with the Program Editor.
Since SAS8.2, you have access to the Enhanced Editor and the code remains.
From the VIEW menu, you should have the choice between using the Enhanced editor and the Program Editor.
Said that, if you want to use the Program Editor with SAS, you can usually press the F4 key to recall the code
Is EG "SAS Enterprise Guide"?
EG only has the Enhanced Editor, I think.