BookmarkSubscribeRSS Feed
deleted_user
Not applicable
I have writen scl program to create word report in SAS/AF, now I must change the client language to Java, so I want use store process to run the scl. I found that then simple scl can run, but the scl to create word report has trouble. It's not log to tell what's wrong,I foung winword process in Windows task manager. So what may cause the problem?
3 REPLIES 3
Cynthia_sas
Diamond | Level 26
Hi!
On this site,
http://support.sas.com/rnd/itech/doc9/dev_guide/stprocess/inet2stp.html
it says:

"The stored process server cannot directly execute SOURCE, MACRO, or SCL catalog entries. You must write a wrapper .sas source code file that executes the catalog entry."
Writing wrapper code is easy -- your .sas program just has the %include or other statements to call your code into the .sas program. If your stored process is going to return a Word document to the client application, you may also need to change the content-type (or HTTP header) using the STPSRV_HEADER function, (inside your code).

Since you are using Java, it sounds to me like you are building a custom web application and will probably be using the Stored Process Web Application, the Stored Process Service API or a combination of both. This web site http://support.sas.com/rnd/itech/doc9/dev_guide/stprocess/webapp.html
says that....

"The Stored Process Service API enables the Java developer to embed stored processes within a Java Web application."
...this site further describes how you would write a custom application and I believe they have an example of wrapper code within that section of the doc. For more specific Java information, consult the developer's guide information which can be found at the links below. (I've included the links for both Java and Windows development.)
cynthia

*** the links ***
http://support.sas.com/rnd/itech/doc9/dev_guide/dist-obj/javaclnt/javaprog/index.html
http://support.sas.com/rnd/itech/doc9/dev_guide/dist-obj/winclnt/index.html
deleted_user
Not applicable
Hi Cynthia, Thanks for your answer.
I have solve the problem, the reason is not patch the office.
Now I can run SAS storeprocess by Java Web application, and I know the method how to get the SAS table. But can I return a value to Java not by SAS table.
Viz. I just only to return a value to Java not want bo by a table.
Cynthia_sas
Diamond | Level 26
Congrats on getting it working! If you did not find your answer in the doc (listed above) about returning a value to Java, then I suggest you contact Tech Support. I think they're your best bet.
cynthia

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 1682 views
  • 0 likes
  • 2 in conversation