BookmarkSubscribeRSS Feed
RobL
Calcite | Level 5

Hello all,

   I am still fairly new to the SAS programming world and I was recently asked a question about the autoexec function. The individual wanted to know if it was possible to add something to the AutoExec so that a specific project would automatically launch during startup. I've not been able to find a solution at this point whether through autoexec or not. Is it possible to have SAS launch a certian project when it first launches?

10 REPLIES 10
collinelliot
Barite | Level 11

Are you using Enterprise Guide or Display Manager? With Display Manager, yes, you can modifiy the shortcut to run a specified .sas file upon lauching SAS. I'm not sure about EG.

collinelliot
Barite | Level 11

The fact that you say "project" suggests you're using EG, however.

RobL
Calcite | Level 5

Thank you for replying. I am using EG at the moment...

collinelliot
Barite | Level 11

Okay, sorry. I'll be curious to see what other responses you get, as I'd like to know how to do this myself. I currently just have a %include "....."; at the top of most of my code that serves this purpose.

PaigeMiller
Diamond | Level 26

You could create an autoexec for each specific project, then a separate shortcut to launch SAS with the desired autoexec. So, if you have "Project A" and "Project B" (creative names, huh?) then each would have it's own SAS shortcut.

--
Paige Miller
RobL
Calcite | Level 5

I will have to give this a try to see if that will be sufficient for the user. Thank you!!

SASKiwi
PROC Star

Please be aware that most EG setups connect to a remote SAS server. The remote servers have their own AUTOEXEC programs that are not EG-aware. However within EG Options you can setup code that will run when you connect to a SAS server. Strictly speaking this is not an AUTOEXEC, but may serve the same purpose:

 

screenshot18.jpg

RobL
Calcite | Level 5

Thank you for the reply. I had seen this in other sets of reference material. I don't believe it would be an issue if it was conifigured for local/single user use. The issue is that I am unfamiliar with the code that would be required to iniate the specific .egp file/report.

collinelliot
Barite | Level 11

At my previous job this is what I did, but now I'm forced to use EG.

Reeza
Super User

Not an autoexec solution, but couldn't you do that from the command line or change the icon functionality?

 

For example if you double click a project it opens directly. If you find the EG icon that's being used, when you go into the windows property you should be able to change that to open the specific project of interest. 

 

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 10 replies
  • 1174 views
  • 2 likes
  • 5 in conversation