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:
Steve G
Past 24 Hours:
0
Prev. 24 Hours:
2
Overall:
5332
People Online:
Visitors:
310
Members:
0
Total:
310
Online Now:
New Topics
S3 Systems Administration
Lawson Security Admin (LSA) - Securing Print Manager to self only
10/24/2025 6:27 PM
Looking for someone who would be willing to share
Lawson Add-Ins for Microsoft Office
Lawson Add-in
9/30/2025 6:51 PM
I am looking for a Lawson Add-ins query to add new
Lawson S3 Procurement
Anyone getting PO 0000 not found for company error in PO23?
9/30/2025 2:45 AM
Anyone getting PO 0000 not found for company error
Lawson Add-Ins for Microsoft Office
PO20 - Cancel PO via Add-in
9/25/2025 8:03 PM
Is it possible to cancel PO's using add-ins? I
S3 Systems Administration
S3 Payroll - PayStubs
9/18/2025 6:58 PM
Looking for a reliable solution to streamline the
S3 Systems Administration
Quick Access report
8/25/2025 7:17 PM
Looking for a good way to see who has access Lawso
S3 Customization/Development
LP01 hiding a PTO plan from the list
8/13/2025 4:44 PM
Hi all. is there a way to hide a specific PTO&n
Lawson Business Intelligence/Reporting/Crystal
GLTrans - PO Line/MAInvdtl
8/6/2025 6:13 PM
Hello, we have an existing tabular model for fina
IPA/ProcessFlow
Retrieving GUID from InforOS
7/25/2025 2:22 AM
Hello everyone, I was wondering if there is a way
IPA/ProcessFlow
IPA for forwarding cost messages (MA64/MA66.3)
7/23/2025 6:07 PM
When a buyer has an invoice cost message where the
Top Forum Posters
Name
Points
Greg Moeller
4184
David Williams
3349
JonA
3293
Kat V
2984
Woozy
1973
Jimmy Chiu
1883
Kwane McNeal
1437
Ragu Raghavan
1377
Roger French
1315
mark.cook
1244
Forums
Filtered Topics
Unanswered
Unresolved
Announcements
Active Topics
Most Liked
Most Replies
Search Forums
Search
Advanced Search
Topics
Posts
Prev
Next
Forums
User Experience
Lawson Design Studio
Trigger PFI from Submit button on LM199
Please
login
to post a reply.
16 Replies
0
Subscribed to this topic
12 Subscribed to this forum
Sort:
Oldest First
Most Recent First
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
Split
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
Split
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
Split
Replace the FC=S with the Function you developed to trigger the flow.
amylynanderson
Advanced Member
Posts: 26
10/28/2010 10:59 AM
Split
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
Split
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
Split
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
Split
amylynanderson
Advanced Member
Posts: 26
10/28/2010 12:32 PM
Split
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
Split
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
Split
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
Split
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
Posts: 3362
10/28/2010 5:40 PM
Split
Are you referring to a &WAIT=true parameter on jobrun.exe ?
amylynanderson
Advanced Member
Posts: 26
10/28/2010 7:04 PM
Split
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
Posts: 3362
10/28/2010 8:10 PM
Split
Use David's query, after the jobrun, and branch accordingly.
amylynanderson
Advanced Member
Posts: 26
10/29/2010 5:43 PM
Split
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
Split
Thanks, I'll try to remember that. It's good to learn new things.
Please
login
to post a reply.