<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:p="urn:schemas-microsoft-com:office:powerpoint" xmlns:a="urn:schemas-microsoft-com:office:access" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema" xmlns:b="urn:schemas-microsoft-com:office:publisher" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:odc="urn:schemas-microsoft-com:office:odc" xmlns:oa="urn:schemas-microsoft-com:office:activation" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:q="http://schemas.xmlsoap.org/soap/envelope/" xmlns:rtc="http://microsoft.com/officenet/conferencing" xmlns:D="DAV:" xmlns:Repl="http://schemas.microsoft.com/repl/" xmlns:mt="http://schemas.microsoft.com/sharepoint/soap/meetings/" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ppda="http://www.passport.com/NameSpace.xsd" xmlns:ois="http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc="http://schemas.microsoft.com/data/udc" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sub="http://schemas.microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:ec="http://www.w3.org/2001/04/xmlenc#" xmlns:sp="http://schemas.microsoft.com/sharepoint/" xmlns:sps="http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:udcs="http://schemas.microsoft.com/data/udc/soap" xmlns:udcxf="http://schemas.microsoft.com/data/udc/xmlfile" xmlns:udcp2p="http://schemas.microsoft.com/data/udc/parttopart" xmlns:wf="http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:dsss="http://schemas.microsoft.com/office/2006/digsig-setup" xmlns:dssi="http://schemas.microsoft.com/office/2006/digsig" xmlns:mdssi="http://schemas.openxmlformats.org/package/2006/digital-signature" xmlns:mver="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mrels="http://schemas.openxmlformats.org/package/2006/relationships" xmlns:spwp="http://microsoft.com/sharepoint/webpartpages" xmlns:ex12t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:ex12m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:pptsl="http://schemas.microsoft.com/sharepoint/soap/SlideLibrary/" xmlns:spsl="http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService" xmlns:Z="urn:schemas-microsoft-com:" xmlns:st="" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta name=Generator content="Microsoft Word 12 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
tt
        {mso-style-priority:99;
        font-family:"Courier New";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang=EN-AU link=blue vlink=purple>
<div class=WordSection1>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Don’t know them that well sorry Karl… but yes the scenario you
describe would be what I would expect.<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>You would need to choose which state to react to. <o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Regards,<o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>Jocelyn <o:p></o:p></span></p>
<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>
<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'>
<p class=MsoNormal><b><span lang=EN-US style='font-size:10.0pt;font-family:
"Tahoma","sans-serif"'>From:</span></b><span lang=EN-US style='font-size:10.0pt;
font-family:"Tahoma","sans-serif"'> sap-wug-bounces@mit.edu
[mailto:sap-wug-bounces@mit.edu] <b>On Behalf Of </b>Karl Nietz<br>
<b>Sent:</b> Thursday, 21 October 2010 11:32 AM<br>
<b>To:</b> SAP Workflow Users' Group<br>
<b>Subject:</b> WF ProgramExists<o:p></o:p></span></p>
</div>
<p class=MsoNormal><o:p> </o:p></p>
<p class=MsoNormal style='margin-bottom:12.0pt'><br>
<span style='font-size:10.0pt;font-family:"Arial","sans-serif"'>Hi Jocelyn,</span>
<br>
<span style='font-size:10.0pt;font-family:"Arial","sans-serif"'>That was quite
useful but I did notice that when a workitem was executed the event STATE_CHG
was published twice. I wonder whether this is because it occurs when you
first reserve the workitem during execution and then again when you complete
execution. No problem for my application but maybe an issue if you only
want to react once during the LUW. </span><br>
<span style='font-size:10.0pt;font-family:"Arial","sans-serif"'>Karl </span><br>
<br>
<o:p></o:p></p>
<table class=MsoNormalTable border=0 cellpadding=0 width="100%"
style='width:100.0%'>
<tr>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif";
color:#5F5F5F'>From:</span> <o:p></o:p></p>
</td>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif"'>"Dart,
Jocelyn" <jocelyn.dart@sap.com></span> <o:p></o:p></p>
</td>
</tr>
<tr>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif";
color:#5F5F5F'>To:</span> <o:p></o:p></p>
</td>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif"'>"SAP
Workflow Users' Group" <sap-wug@mit.edu></span> <o:p></o:p></p>
</td>
</tr>
<tr>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif";
color:#5F5F5F'>Date:</span> <o:p></o:p></p>
</td>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif"'>19/10/2010
10:31 AM</span> <o:p></o:p></p>
</td>
</tr>
<tr>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif";
color:#5F5F5F'>Subject:</span> <o:p></o:p></p>
</td>
<td valign=top style='padding:.75pt .75pt .75pt .75pt'>
<p class=MsoNormal><span style='font-size:7.5pt;font-family:"Arial","sans-serif"'>RE:
WF ProgramExists</span><o:p></o:p></p>
</td>
</tr>
</table>
<p class=MsoNormal><o:p> </o:p></p>
<div class=MsoNormal align=center style='text-align:center'>
<hr size=2 width="100%" noshade style='color:#A0A0A0' align=center>
</div>
<p class=MsoNormal style='margin-bottom:12.0pt'><br>
<br>
<br>
<tt><span style='font-size:10.0pt'>Mike - Try the state change event - Yes that
should be usable when the work item is forwarded, reserved or replaced. </span></tt><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<tt>Regards,</tt><br>
<tt>Jocelyn </tt><br>
<br>
<tt>-----Original Message-----</tt><br>
<tt>From: sap-wug-bounces@mit.edu [</tt></span><a
href="mailto:sap-wug-bounces@mit.edu"><tt><span style='font-size:10.0pt'>mailto:sap-wug-bounces@mit.edu</span></tt></a><tt><span
style='font-size:10.0pt'>] On Behalf Of Mike Pokraka</span></tt><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<tt>Sent: Monday, 18 October 2010 9:20 PM</tt><br>
<tt>To: SAP Workflow Users' Group</tt><br>
<tt>Subject: Re: WF ProgramExists</tt><br>
<br>
<tt>Hi Kjetil,</tt><br>
<br>
<tt>Doesn't address the question whether it gets called during forwarding, but</tt><br>
<tt>a much more useful piece of info instead, thanks!</tt><br>
<br>
<tt>Mike</tt><br>
<br>
<tt>On Mon, October 18, 2010 10:21 am, Kjetil Kilhavn wrote:</tt><br>
<tt>> Fredag 15. oktober 2010 09.44.51 skrev Mike Pokraka:</tt><br>
<tt>>> Hi Rick,</tt><br>
<tt>>></tt><br>
<tt>>> No I haven't played with them, but looks like there's some good
stuff</tt><br>
<tt>>> there. If the forwarding isn't catchable in the WF exit, you could
do a</tt><br>
<tt>>> small enhancement somewhere in the forwarding functionality.</tt><br>
<tt>></tt><br>
<tt>> It's been a while since I examined IF_SWF_IFS_WORKITEM in order to
find</tt><br>
<tt>> out if</tt><br>
<tt>> I could use this interface to log some information in a solution's WF
log</tt><br>
<tt>> instead of using separate logging tables, but here's my findings about
the</tt><br>
<tt>> sequence of method invocations anyway - for what it is worth:</tt><br>
<tt>></tt><br>
<tt>> WI type | BC | AR | C | BE
| SC | AE | AA | BR |</tt><br>
<tt>> ---------------------------------------------------------------</tt><br>
<tt>> W (dialog) | 1 | 2 (a) | 3 |
| | | | |</tt><br>
<tt>> B (backgr.) | | |
| 1 | 2 | 3 | |
|</tt><br>
<tt>> | |
| | | 4,5 |
| | |</tt><br>
<tt>> F (flow) | 1 | 6,7,8,9, | 2 | 3 | 4,5,
| 10,| | |</tt><br>
<tt>> | | 13,14,15,|
| | 11,12 | | |
|</tt><br>
<tt>> | | 16,17
| | | |
| | |</tt><br>
<tt>> ---------------------------------------------------------------</tt><br>
<tt>> (a) Not if no agent is found</tt><br>
<tt>></tt><br>
<tt>> BC - BEF_CREAT</tt><br>
<tt>> AE - AFT_REXEC</tt><br>
<tt>> C - CREATED</tt><br>
<tt>> BE - BEF_EXEC</tt><br>
<tt>> SC - STATE_CHG</tt><br>
<tt>> AE - AFT_EXEC</tt><br>
<tt>> AA - AFT_ASYINV</tt><br>
<tt>> BR - BEF_REMOVE</tt><br>
<tt>></tt><br>
<tt>> Well, as I can recall it was the *sequence* I made a note of, my
memory</tt><br>
<tt>> may of</tt><br>
<tt>> course be failing ;-)</tt><br>
<tt>></tt><br>
<tt>>></tt><br>
<tt>>> Cheers,</tt><br>
<tt>>> Mike</tt><br>
<tt>>></tt><br>
<tt>>> On Thu, October 14, 2010 4:26 pm, Sample, Rick wrote:</tt><br>
<tt>>> > Mike,</tt><br>
<tt>>> ></tt><br>
<tt>>> > That is sort of what I have right now. Pre/Post BG steps on
these</tt><br>
<tt>>> > approval tasks.</tt><br>
<tt>>> > I have a wee bit of time to play around with these WF Program
Exits</tt><br>
<tt>>> and</tt><br>
<tt>>> > determine if I have valid use 'without' over engineering my
WF.</tt><br>
<tt>>> > It looks doable and some simple container ops seem to work...
mostly</tt><br>
<tt>>> > anyway.</tt><br>
<tt>>> ></tt><br>
<tt>>> > I am hacking some of the class files in the SWF_TST package.
First try</tt><br>
<tt>>> > was the WF Trace.</tt><br>
<tt>>> > That did not work. Won't turn on via the class file.
Annoying, but got</tt><br>
<tt>>> > the container ops</tt><br>
<tt>>> > code and kicking around.</tt><br>
<tt>>> ></tt><br>
<tt>>> > You use this functionality?</tt><br>
<tt>>> ></tt><br>
<tt>>> > I plan to spend a day or two more and see what I can get out
of these</tt><br>
<tt>>> > class files.</tt><br>
<tt>>> ></tt><br>
<tt>>> > As always, thanks for the feedback.</tt><br>
<tt>>> > Rick</tt><br>
<tt>>> ></tt><br>
<tt>>> >> -----Original Message-----</tt><br>
<tt>>> >> From: sap-wug-bounces@mit.edu [</tt></span><a
href="mailto:sap-wug-"><tt><span style='font-size:10.0pt'>mailto:sap-wug-</span></tt></a><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<tt>>> >> bounces@mit.edu] On Behalf Of Mike Pokraka</tt><br>
<tt>>> >> Sent: Thursday, October 14, 2010 8:03 AM</tt><br>
<tt>>> >> To: SAP Workflow Users' Group</tt><br>
<tt>>> >> Subject: RE: WF ProgramExists</tt><br>
<tt>>> >></tt><br>
<tt>>> >> Rick,</tt><br>
<tt>>> >></tt><br>
<tt>>> >> Just a general comment which may not apply, but I find</tt><br>
<tt>>> >> that I tend to do role resolution separately more often</tt><br>
<tt>>> >> than not as it avoids most of these conundrums.</tt><br>
<tt>>> >> To accomplish your scenario I'd use two conditional texts
in</tt><br>
<tt>>> >> my work item and pass in a flag to display one or the
other.</tt><br>
<tt>>> >> It may be possible to catch the forwarding action via a
work</tt><br>
<tt>>> >> item exit (not sure & no time to look into it) and
change</tt><br>
<tt>>> >> the flag in the container - the new text would be
displayed</tt><br>
<tt>>> >> automatically for the new user.</tt><br>
<tt>>> >></tt><br>
<tt>>> >> Cheers,</tt><br>
<tt>>> >> Mike</tt><br>
<tt>>> >></tt><br>
<tt>>> >> On Thu, October 14, 2010 1:12 pm, Sample, Rick wrote:</tt><br>
<tt>>> >> > Sorry, dumb question. I know a flag gets set
somewhere,</tt><br>
<tt>>> >></tt><br>
<tt>>> >> because of the</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > option</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > to fail the role if FM failed. "Terminate if
Rule Resolution</tt><br>
<tt>>> >></tt><br>
<tt>>> >> has no</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > Result".</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Most WFs we have a 'Fail Back' option. If role fails
to find</tt><br>
<tt>>> >></tt><br>
<tt>>> >> next</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > agent in approval,</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > send back to last agent with a changed TEXT to
inform</tt><br>
<tt>>> >></tt><br>
<tt>>> >> user what to do</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > next.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > User can manually forward, whatever...</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > What appears to be a better option is to get last
agent</tt><br>
<tt>>> >></tt><br>
<tt>>> >> and compare to</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > the current agent.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > The event AFT_REXEC "after rule executed",
looks like it is</tt><br>
<tt>>> >></tt><br>
<tt>>> >> what I want.</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > Will forward findings if anyone cares...</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Thanks,</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Rick</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > From: sap-wug-bounces@mit.edu [</tt></span><a
href="mailto:sap-wug-"><tt><span style='font-size:10.0pt'>mailto:sap-wug-</span></tt></a><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<tt>>> >></tt><br>
<tt>>> >> bounces@mit.edu] On</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > Behalf Of Steffen Schloenvoigt</tt><br>
<tt>>> >> > Sent: Thursday, October 14, 2010 4:58 AM</tt><br>
<tt>>> >> > To: SAP Workflow Users' Group</tt><br>
<tt>>> >> > Subject: Re: WF ProgramExists</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Hmm no, but you could try to use FM</tt><br>
<tt>>> >></tt><br>
<tt>>> >> 'SAP_WAPI_WORKITEM_RECIPIENTS' and</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > check if the result is empty...</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Best regards,</tt><br>
<tt>>> >> > Steffen Schlönvoigt</tt><br>
<tt>>> >> > 2010/10/13 Sample, Rick</tt><br>
<tt>>> >></tt><br>
<tt>>> >> <Rick.Sample@graybar.com<</tt></span><a
href="mailto:Rick.Sample@graybar.c"><tt><span style='font-size:10.0pt'>mailto:Rick.Sample@graybar.c</span></tt></a><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<tt>>> >> om>></tt><br>
<tt>>> >></tt><br>
<tt>>> >> > Update,</tt><br>
<tt>>> >> > I figured out how to update the WI_TEXT with some
code</tt><br>
<tt>>> >></tt><br>
<tt>>> >> in</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > CL_SWL_ADM_COMMAND-WITEXT_CHANGE.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Now, I would like to change this WI_TEXT on failure
of the</tt><br>
<tt>>> >></tt><br>
<tt>>> >> role res.</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > Example, if</tt><br>
<tt>>> >> > role res fails, set the WI_TEXT to "Error, bla
bla bla you</tt><br>
<tt>>> >></tt><br>
<tt>>> >> received</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > this because could not find next agent... "</tt><br>
<tt>>> >> > Right now, I have to execute the role res in a
background</tt><br>
<tt>>> >></tt><br>
<tt>>> >> task just to</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > figure out if next agent is found, set the message
if not,</tt><br>
<tt>>> >></tt><br>
<tt>>> >> etc. Then,</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > execute the Decision task (which executes the role
res</tt><br>
<tt>>> >></tt><br>
<tt>>> >> again) and send</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > to last agent.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Question: Is there a flag in Work Item container that
is set</tt><br>
<tt>>> >></tt><br>
<tt>>> >> if role</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > fails?</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > From: Sample, Rick</tt><br>
<tt>>> >> > Sent: Wednesday, October 13, 2010 8:53 AM</tt><br>
<tt>>> >> > To: SAP Workflow Users' Group</tt><br>
<tt>>> >> > Subject: WF ProgramExists</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Hi all,</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > I have a need for a WF "Program Exit" to
dynamically</tt><br>
<tt>>> >></tt><br>
<tt>>> >> change the Task</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > Text at runtime.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Currently, if I need to change a task text at
runtime, I</tt><br>
<tt>>> >></tt><br>
<tt>>> >> create a</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > container element and</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > place it in the WI_TEXT. I then have a background
task</tt><br>
<tt>>> >></tt><br>
<tt>>> >> determine what</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > the task text should be and</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > pass it in before the Decision step is executed.
Kludgy, but</tt><br>
<tt>>> >></tt><br>
<tt>>> >> it works</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > and fairly simple to understand.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Now, I want to dynamically change this value using a</tt><br>
<tt>>> >></tt><br>
<tt>>> >> Program Exit.</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > So I added the SAP standard</tt><br>
<tt>>> >></tt><br>
<tt>>> >> CL_SWF_TST_PE_GETDESCRIPTION class to a</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > new task and</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > it gets the Desc text and sets a container. Fine.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Next, I modified this class to just get/set a Work
Item</tt><br>
<tt>>> >></tt><br>
<tt>>> >> container.</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > This also works fine.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Now, I tried to get this to change the Task Text
with this</tt><br>
<tt>>> >></tt><br>
<tt>>> >> new</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > container element but no luck.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > This changes the container element, but does not
change</tt><br>
<tt>>> >></tt><br>
<tt>>> >> the Work Item</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > text.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Anyone use these WF program exits?</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Any thoughts, examples, assistance is greatly
appreciated.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > ==================================</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > METHOD change_cont_element.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > DATA:</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > container TYPE REF TO
if_swf_cnt_container,</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > lh_wihandle TYPE REF TO
if_swf_run_wim_internal,</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > l_exception TYPE REF TO
cx_swf_cnt_container,</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > l_wiid TYPE sww_wiid.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > BREAK-POINT ID zexits.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > l_wiid = me->m_ctx->get_workitem_id( ).</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > TRY.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > lh_wihandle =</tt><br>
<tt>>> >></tt><br>
<tt>>> >> cl_swf_run_wim_factory=>find_by_wiid( l_wiid ).</tt><br>
<tt>>> >></tt><br>
<tt>>> >> > container =
lh_wihandle->get_wi_container( ).</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > CATCH cx_swf_run_wim.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > ENDTRY.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > TRY.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > CALL METHOD
container->element_get</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > EXPORTING</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > name =
'ZWI_TEXT'.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > CALL METHOD
container->element_set</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > EXPORTING</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > name
= 'ZWI_TEXT'</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > value
= 'New_Text'</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > IMPORTING</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > exception_return
= l_exception.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > CATCH cx_swf_tst_introspection_error.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > CATCH cx_swf_cnt_container.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > ENDTRY.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > ENDMETHOD.</tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> ></tt><br>
<tt>>> >> > Rick Sample | SAP Workflow Analyst/Developer</tt><br>
<tt>>> >> > 11885 Lackland Road | Maryland Heights, MO 63146 |</tt><br>
<tt>> --</tt><br>
<tt>> Kjetil Kilhavn (+47 40220607)</tt><br>
<tt>> Blue Consulting AS (</tt></span><a href="http://www.bluec.no/"><tt><span
style='font-size:10.0pt'>http://www.bluec.no</span></tt></a><tt><span
style='font-size:10.0pt'>)</span></tt><span style='font-size:10.0pt;font-family:
"Courier New"'><br>
<tt>></tt><br>
<tt>> _______________________________________________</tt><br>
<tt>> SAP-WUG mailing list</tt><br>
<tt>> SAP-WUG@mit.edu</tt><br>
<tt>> </tt></span><a href="http://mailman.mit.edu/mailman/listinfo/sap-wug"><tt><span
style='font-size:10.0pt'>http://mailman.mit.edu/mailman/listinfo/sap-wug</span></tt></a><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<tt>></tt><br>
<br>
<br>
<tt>_______________________________________________</tt><br>
<tt>SAP-WUG mailing list</tt><br>
<tt>SAP-WUG@mit.edu</tt><br>
</span><a href="http://mailman.mit.edu/mailman/listinfo/sap-wug"><tt><span
style='font-size:10.0pt'>http://mailman.mit.edu/mailman/listinfo/sap-wug</span></tt></a><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<br>
<tt>_______________________________________________</tt><br>
<tt>SAP-WUG mailing list</tt><br>
<tt>SAP-WUG@mit.edu</tt><br>
</span><a href="http://mailman.mit.edu/mailman/listinfo/sap-wug"><tt><span
style='font-size:10.0pt'>http://mailman.mit.edu/mailman/listinfo/sap-wug</span></tt></a><span
style='font-size:10.0pt;font-family:"Courier New"'><br>
<br>
</span><o:p></o:p></p>
</div>
</body>
</html>