BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
DavidPhillips2
Rhodochrosite | Level 12

I am using SAS Information Delivery Portal 4.2 to display a stored procedure in a SAS Stored Process Portlet.  I included a refresh button to update the stored procedure each time the user changes a dropdown option.  The user experiences an extra login that I would like to remove. 

First the user logs into SAS Information Delivery Portal 4.2 where the user is prompted for credentials.  Then the user clicks on the tab containing the portlet.  The stored procedure shows correctly.  The user changes a dropdown parameter.  The user clicks refresh.  The stored procedure calls a postback method and reloads the page. Only on the first time the page refreshes is the user prompted for credentials, clicking refresh again will not prompt the user. 

The post back call is:

PUT "<FORM METHOD='POST' ACTION='https://server1.com/SASStoredProcess/do'>";

The driver method is

/*driver function for displaying the form*/

%MACRO DisplayForm();

     DATA _null_;

     FILE _WEBOUT;

     PUT "<html>";

     PUT "<body>";

     PUT "<div style='font-family: Verdana; font-size: 8pt;'>";

     PUT "<CENTER>";

     PUT "<FORM METHOD='POST' ACTION='https://server1.com/SASStoredProcess/do'>";

PUT "<input type='hidden' name='_program' value='/Users/User_Name/My Folder/Stored Procedure Name' />";

    

     PUT "<input type='hidden' name='_action' value='EXECUTE' />";

     DATA _null_;

     file _webout;

     PUT "<tr>";

     PUT "<td colspan='2'>";

     PUT "<input type='submit' style='font-family: Verdana; font-size: 8pt;' class='button' value='Refresh' />";

     PUT "</td>";

     PUT "</tr>";

     Run;

     %ProcessReport();

     DATA _null_;

     file _webout;

     PUT "</table>";

     PUT "</FORM>";

     PUT "</CENTER>";

     PUT "</div>";

     PUT "</body>";

     PUT "</html>";

     file _webout;

     RUN;

%MEND DisplayForm;

1 ACCEPTED SOLUTION
1 REPLY 1

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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
  • 1 reply
  • 1343 views
  • 0 likes
  • 1 in conversation