Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

The 4th edition of the Campaign Community Lens newsletter is out now!
SOLVED

Trigger a workflow using Dynamic JSSP page

Avatar

Level 2

Hi All.

I want to trigger a workflow using dynamic JSSP page. I have configured the workflow with external signal .In the JSSP page i wrote a postEvent method

<%@ page import="xtk:server/jsspcontext.js"   %>

<%@ page import="/nl/core/shared/nl.js,nms:amcIntegration.js"%>

<%

NL.require("/nl/core/api.js")

.require('/nl/core/queryDef.js')

.require('/nl/core/shared/xtk.js');

xtk.workflow.PostEvent("WKF11", "signal", "", "", false)

%>

When i access the JSSP page in the browser.

XTK-170019 Access denied.

SOP-330011 Error while executing the method 'PostEvent' of service 'xtk:workflow'.

1 Accepted Solution

Avatar

Correct answer by
Level 5

I guess this is a late reply. However, the solution might be the following.

As per the jssp page, the user/operator is anonymous. Hence you need to login.

<% var oldContext = logon('john-doe', 'password'); // login as john-doe
for(var i in application.operator){
  document.write(i+': '+application.operator[i]+'\n');

}

Use this inside jssp page. That should work for you. Reference:

.https://blog.floriancourgey.com/2018/11/create-jssp-dynamic-javascript-server-page-in-acc/

View solution in original post

1 Reply

Avatar

Correct answer by
Level 5

I guess this is a late reply. However, the solution might be the following.

As per the jssp page, the user/operator is anonymous. Hence you need to login.

<% var oldContext = logon('john-doe', 'password'); // login as john-doe
for(var i in application.operator){
  document.write(i+': '+application.operator[i]+'\n');

}

Use this inside jssp page. That should work for you. Reference:

.https://blog.floriancourgey.com/2018/11/create-jssp-dynamic-javascript-server-page-in-acc/