Login
Register
Search
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Forums
User Experience
Lawson Design Studio
Trigger PFI from Submit button on LM199
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Who's On?
Membership:
Latest:
TomV
Past 24 Hours:
1
Prev. 24 Hours:
2
Overall:
5186
People Online:
Visitors:
183
Members:
0
Total:
183
Online Now:
New Topics
Lawson Landmark
LPL INSTR Functions
4/5/2024 8:32 PM
I'm writing a simple report using the Create R
Infor SCM
Translating 856 to get the ~ REF^CN^ field
4/3/2024 8:24 PM
We are trying to get the tracking number which is
IPA/ProcessFlow
Sample XML file create Flow
4/3/2024 3:43 PM
Hello everyone, I am new to creating XML files
Lawson S3 HR/Payroll/Benefits
bn105 error message
3/26/2024 6:40 PM
I need to change some of the set ups in our Life I
IPA/ProcessFlow
IPA executing Job
3/13/2024 7:08 PM
New to the IPA world and was wondering, can an IPA
Lawson S3 HR/Payroll/Benefits
Life Age Reduction on benefits plans
3/12/2024 7:15 PM
For our optional life we have an age based coverag
Lawson S3 HR/Payroll/Benefits
BN53.1 Add-In
3/7/2024 3:31 PM
We are migrating to Solstice. They require a
Lawson Business Intelligence/Reporting/Crystal
Domain Name Change
3/5/2024 7:45 PM
Our domain name needs to change and was hoping I c
S3 Customization/Development
Cobol calling Shell Script
2/29/2024 1:27 PM
Has anyone created or modified a Lawson Cobol prog
Infor ION
ION vs IPA
2/29/2024 1:24 AM
We had a person new to Lawson and Infor go to Info
Top Forum Posters
Name
Points
Greg Moeller
4184
David Williams
3349
JonA
3288
Kat V
2984
Woozy
1973
Jimmy Chiu
1883
Kwane McNeal
1437
Ragu Raghavan
1348
Roger French
1311
mark.cook
1244
Forums
Unanswered
Active Topics
Most Liked
Most Replies
Search Forums
Search
Advanced Search
Topics
Posts
Prev
Next
Forums
Lawson Design Studio
Trigger PFI from Submit button on LM199
Sort:
Oldest First
Most Recent First
You are not authorized to post a reply.
Author
Messages
amylynanderson
Advanced Member
Posts: 26
10/27/2010 6:29 PM
I am trying to use java to do this.
I cannot find a variable that is unique enough to say it is a submit.
The message on all transactions is submit
The fc code is not set for a button.
I know my ags call works but I only want it to happen when they submit the job.
Any suggestions, Amy
David Williams
Veteran Member
Posts: 1127
10/27/2010 6:38 PM
Do you have Design Studio? If so, replace the Submit function with a function that will trigger ProcessFlow (using an AGS call to WFWK.1). The flow could run the job (pass userid and jobname to the flow) and then do whatever else you need the flow to do once the job is done.
amylynanderson
Advanced Member
Posts: 26
10/27/2010 6:49 PM
I have Design Studio that is what I was trying to write the java script in as FORM_OnAfterTransaction.
When you say replace the submit function do you mean replace the action on the properties button?
What would I replace it with? Why Type of function? Currently has FC=S which I have not clue why I cannot address the field.
Thanks Amy
David Williams
Veteran Member
Posts: 1127
10/27/2010 7:26 PM
Replace the FC=S with the Function you developed to trigger the flow.
amylynanderson
Advanced Member
Posts: 26
10/28/2010 10:59 AM
function FORM_OnBeforeTransaction(fc)
{
// was the transaction successful?
if (formState.agsError) return;
// following an submit transaction, trigger flow
if (fc == "S")
{
var vMessage="Lease PFI was Triggered";
alert(vMessage);
var s = portalWnd.AGSPath+"?_PDL="+
"FOCUSQA&_TKN=WFWK.1&_EVT=ADD&_RTN=DATA&_LFN=ALL&_TDS=IGNORE"+
"&FC=A&SERVICE=LMEXPIRING&WORK-TITLE=LM199TriggerLMEXPIRING"+
"&_DELIM=%09&_OUT=XML&_EOT=TRUE";
portalWnd.httpRequest(s);
}
return true;
}
FORM_OnBeforeTransaction()
or
FORM_OnBeforeTransaction(fc)
error on page
amylynanderson
Advanced Member
Posts: 26
10/28/2010 11:06 AM
My main problem here too is FC is not initialized. If I leave FC out completely it will execute everytime even it they inquire.
I have a word doc with print screen but am not able to attach here
Thanks Amy
David Williams
Veteran Member
Posts: 1127
10/28/2010 11:26 AM
Change the name of your function: function triggerMyFlow()
Change the Action of your Submit button to Function and select your function.
David Williams
Veteran Member
Posts: 1127
10/28/2010 11:27 AM
amylynanderson
Advanced Member
Posts: 26
10/28/2010 12:32 PM
That worked ... now I just need to figure out how to pass the jobname, user id and company to the PFI to webrun the job first. Thanks for you help.
David Williams
Veteran Member
Posts: 1127
10/28/2010 1:09 PM
Add the variables to your Service and pass them in your AGS call:
var s = portalWnd.AGSPath+"?_PDL="+
"FOCUSQA&_TKN=WFWK.1&_EVT=ADD&_RTN=DATA&_LFN=ALL&_TDS=IGNORE"+
"&FC=A&SERVICE=LMEXPIRING&WORK-TITLE=LM199TriggerLMEXPIRING"+
"&VARIABLE-NAMEr0=USERID" +
"&VARIABLE-VALUEr0=" + lawForm.getFormValue("text1") +
"&VARIABLE-NAMEr1=JOBNAME" +
"&VARIABLE-VALUEr1=" + lawForm.getFormValue("text2") +
"&_DELIM=%09&_OUT=XML&_EOT=TRUE";
amylynanderson
Advanced Member
Posts: 26
10/28/2010 4:42 PM
thanks got the job working. But I do not want the flow to continue if the job goes into needs recovery or invalidate paramenters. I have the WAIT=true so at least it will wait until the job is done before continuing. What do I put in the success string field on the webrun to indicate success?
David Williams
Veteran Member
Posts: 1127
10/28/2010 4:55 PM
I'm not sure. You could always Query the QUEUEDJOB table to make sure the job didn't go into Waiting status.
http://consultdavidw.blog...ou-would-use-to.html
John Henley
Senior Member
Posts: 3348
10/28/2010 5:40 PM
Are you referring to a &WAIT=true parameter on jobrun.exe ?
amylynanderson
Advanced Member
Posts: 26
10/28/2010 7:04 PM
NO, I am using that. The results to check if the job completed successful. How can I do that? The WAIT=true does not stay on the node when a job goes into Needs recovery or Invalid parms too. If either of these situation happen I do not want to go to the next node.
Thanks Amy
John Henley
Senior Member
Posts: 3348
10/28/2010 8:10 PM
Use David's query, after the jobrun, and branch accordingly.
amylynanderson
Advanced Member
Posts: 26
10/29/2010 5:43 PM
Just an FYI on what I did to solve my problem of verifying the report did not go into need recorvery or invalid parameters.
I changed the webrun node to a syscommand node
/bin/wtsubmit -v | grep | wc -l
ERROR = Abnormal
After this node I put a branch to test for outputData = 0 Job Completed Success outputData = 1 Job Needs Attention
David Williams
Veteran Member
Posts: 1127
10/29/2010 5:51 PM
Thanks, I'll try to remember that. It's good to learn new things.
You are not authorized to post a reply.