How to automate the approval procees of a document in UWL?

Hi All,
I am using the action Inbox connector to publish a document in KM after after approval.
My requirement is that the doc shud be approved automatically  if the manager doesn't approves in a particular timespan.
The action handler for the approve action in UWL xml is com.sap.km.approve.
Please guide me how to achieve this.
Regards,
Sumit

Hi Sumit,
In order to publish a document you could try something like this:
IResource resource = ....;
IStatemanagementManager service = (IStatemanagementManager)ResourceFactory.getInstance().getServiceFactory().getRepositoryService(resource, "StatemanagementRepositoryService");
IStatemanagementResource smResource = service.getStatemangementResource(resource);
IResourceTransition resourceTransition = smResource.getTransition("lbl.skip.tobereleased");
boolean success = resourceTransition.execute();
Now this will only work if the user in the ResouceContext is an owner of the resource and if the resource is in "To be released" status.
For a better understanding of the process decompile km.appl.repository.service.statemanagement_core.jar and study the code.
Best regards,
Avishai Zamir

Similar Messages

  • How to find the approval status for a document version

    Hi all,
    We have enabled versioning on a folder and the system is maintaining the versions. I need to be able to identify which version in at what status.
    For example, I create a file and it creates a version, I check it in and out several times, I then release/publish the file, and another version is created, I then check it out and in several times and the cycle begins again.
    I then realize that I need to go back to the latest released version but I don't know which one it is nor can I identify it using the 'versions' selection from details. How do I know what the status is of the previous versions?
    I need to be able to identify only those versions, past and present, that were 'approved/released' vs those that were left in progress. How do I find the statuses of the previous versions to correctly identify which version was released.
    KM is maintaining this some how because it knows to show only those items that are released to the standard user and not show them those that are in progress.
    How do I find that same parameter that shows me which older version is release?
    I am looking for something like what is available with the properties selection on the 'versions' screen. I am able to go to any version and look at the properties of that version at the time the version was saved. This is what I need with status. I need to be able to look at any version and know what status was at the time it was saved.
    Any help is appreciated,
    Srini

    Hi
    According to my knowledge,Versioning can only be done on files, not folders.
    To view the version history of a file, as well as save prior revisions to another location to view them do this:
           1.      Using Windows Explorer, locate the file.
           2.      Right-click the file and select Versioning and then select List Version History.
    The resulting dialog displays the version history of this file.
           3.      Select a prior version and click the Save As button to save the version to another location.
    Regards
    Elizabeth

  • How to automate the generation of several Word documents into PDF?

    I want to generate in batch processes the conversion from Word documents into PDF. Could you tell me how?
    Thank yoou.

    Thank you for your answers.
    But I would like to launch a batch to generate PDFs and I don't find any explanation in the Adobe documentation telling how to do.
    Do you have any idea?

  • OB52 Posting Period Close:  Does anyone know how to automate the close?

    Does anyone know how to automate the FI Period Close (trans code OB52)?  Currently, the business users go into the screen and open and close any periods manually.  For the MM period close, we are able to do so because we found the program to use in the batch job.  For some reason, the FI side shows the program SAPL0F00 but this is only a view and will not allow a batch job to be created.  Does anyone know of the actual program used for the FI period close?

    Use program RFPERIOD_OPEN.  It may help.  For further details you may check the following thread.
    RFPERIOD_OPEN

  • How to automate the flatten transparency in illustrator?

    How to automate the "Flatten Transparency option" in illustrator via javascript. Please share with me.
    Thanks

    I'm looking for the same thing.
    app.executeMenuCommand('Flatten Transparency'); works in CC but all it does is it brings up the window and you still have to click OK to make the script continue.
    Before anyone asks why do  you want to do it etc. In print thereare instances where you have to open and edit (not text) large numbers of pdfs to change colours, outline fonts etc otherwise there's trouble on print devices.
    My script for instance looks for 100K blacks and replaces them with rich black, looks for empty text frames, overprint, bleed settings, clipping paths etc.
    The only way to edit successfully a pdf without fonts is to place it and flatten transparency outlining fonts and then work on it.
    So back to the point. After the window pops up, is there a way to simulate a keystroke like "Enter" or maybe app.executeMenuCommand('Flatten Transparency'); takes arguments like:
    app.executeMenuCommand('Flatten Transparency',preset_name);...?
    Anyone? Adobe SDK team? :-)

  • How to automate the data load process using data load file & task Scheduler

    Hi,
    I am doing Automated Process to load the data in Hyperion Planning application with the help of data_Load.bat file & Task Scheduler.
    I have created Data_Load.bat file but rest of the process i am unable complete.
    So could you help me , how to automate the data load process using Data_load.bat file & task Scheduler or what are the rest of the file is require to achieve this.
    Thanks

    To follow up on your question are you using the maxl scripts for the dataload?
    If so I have seen and issue within the batch (ex: load_data.bat) that if you do not have the full maxl script path with a batch when running it through event task scheduler the task will work but the log and/ or error file will not be created. Meaning the batch claims it ran from the task scheduler although it didn't do what you needed it to.
    If you are using maxl use this as the batch
    "essmsh C:\data\DataLoad.mxl" Or you can also use the full path for the maxl either way works. The only reason I would think that the maxl may then not work is if you do not have the batch updated to call on all the maxl PATH changes or if you need to update your environment variables to correct the essmsh command to work in a command prompt.

  • How to automate the exchange rates in BI

    Hi Guys
    can any one let me know the step by step approach of how to automate the exchange rates in BI...I know that if we right click in source system and say transfer exchange rates ..we will get those values ....But I want to automate this process in BI with a Process chain...I have created a start variant and connected it to a ABAP process type and calling the RSIMPCURR programm in sync..local....Do I need to call any Program event ? Iam not able automate this..please advice step by stepp
    After ABAP process type do I need to create any other steps ?
    regards

    Hi,
    All you have to do is to define the ABAP Process as new process variant, call mode syncronous, called from local, program name RSIMPCURR, and define a program variant for example number 12 and create it, there you select the update exchange rates., go to attributes, give a meaning and save all. You can automate the start of the porocess chain and select it as period job.
    Regards
    MK

  • How to automate the Acrobat Reader plugin in Internet Explorer

    Hi,
    I have been trying to figure out how to automate the Acrobat Reader plugin in Internet Explorer. My goal is to find a way to allow users of our web application to print PDFs to the default printer without having to go through the plugin's GUI. Our application includes a browser helper component, and I had hoped it would be possible to use the IWebBrowser2 interface's get_Document() method to get at some sort of interface to the plugin (as is possible for, say, a Word document hosted in Internet Explorer) and then use this to print the document. However, this does not work: get_Document(), when called on an IWebBrowser2 instance with a PDF loaded, returns E_NOINTERFACE. I also tried calling the IWebBrowser2 interface's ExecWB() method with OLECMDID_PRINT, OLECMDEXECOPT_DONTPROMPTUSER, and PRINT_DONTBOTHERUSER, and printed a blank page rather than the PDF.
    Is it possible to do what I am attempting? Like I said, my core goal is to print a PDF from within Internet Explorer without requiring user interaction. I'd appreciate any suggestions as to how I might accomplish this -- it doesn't _have_ to be by automating the plugin (maybe that is a the wrong approach... though it sure would be nice if the plugin provided access to its object model via IWebBrowser2->get_Document()).
    Thanks in Advance,
    Steve Mckinney
    Senior Developer
    Paxon Corporation

    IF that were entirely true, then the whole purpose of this thread is moot (automating printing server side). It is possible to load the file via URLs using the following html code:
    "<"body>
    "<"OBJECT id="pdf"
    type="application/pdf"
    width=800
    height=600 >
    "<"param name="src" value="http://localhost/pdfs/vorder_nc.pdf"/>
    "<"/OBJECT>
    "<"script language="JavaScript">
    function waitLoad()
    setTimeout("printFile()",2000);
    function printFile()
    var objPdf = document.getElementById('pdf');
    objPdf.PrintAllFit(1);
    "<"/script>
    "<"/body>
    So, if I used php or some other scripting language on the server to fill in the name of the pdf, I can load it via a URL, wait a couple of seconds for it to load, and then print it without user interaction. I wish that the LoadFile method would load a URL so that when it returns, I know it is loaded and I don't have to put faith in a timer that may not be enough for a large file.
    This is the situation I'm in. This way works but I don't like the timer. I'd rather have the plugin let me know when it's loaded. Is there another method that can help me do what I want?
    Thank again.

  • How to automate the data flow to content servers?

    We have ECC connected to CS. Could you help tell how to automate the data flow into the CS? Thanks a lot!

    What do you use the Content Server for? If its for archiving you need to run the STORE job to send the data to the CS.
    I can't see a reason to automate that process
    Regards
    Juan

  • My designs are not showing, how long is the approval process

    My designed personas are not showing, how long is the approval process
    == This happened ==
    Not sure how often
    == Next day after uploading

    A few days to a week, give or take.

  • How to remove the approved order from the table in sapui5

    Hi Experts,
      how to remove the approved order from the table in sapui5.
    After Approving the order how to remove the order from the table in sapui5.
    Please help me.
    Thanks & regards
    chitti Babu

    Hi,
    Probelm is OBIEE on your machine.Some one might have deleted pdf option.
    Refer : http://obiee101.blogspot.com/2009/07/obiee-dashboard-default-controls.html
    Try to find out tag that is to be removed from controlmessages.xl so that you have only HTML.
    Update :
    Stop BI Server.Try removing below tag and restart server.
    (sawm:if name="enablePDF">(a class="NQWMenuItem" name="pdf" href="javascript:void(null)" onclick="return PortalPrint('@{pdfURL}[javaScriptString]',@{bNewWindow});">
    <sawm:messageRef name="kmsgDashboardPrintPDF"/></a)</sawm:if)
    Regards,
    Srikanth
    Edited by: Srikanth Mandadi on Apr 19, 2011 3:36 AM

  • How to find the approver from request key

    How to determine the approver from request key.
    If the approver is a group where do i find the correlation.
    I have checked WFTASK and WFTASK HISTORY but unable to correlate. This is with respect to OIM 11G R2
    Many Thanks

    select IDENTIFICATIONKEY, TASKID, TASKGROUPID, TASKNUMBER, OUTCOME, STATE, ASSIGNEDDATE, Assignees, APPROVERS, TASKDEFINITIONNAME, CREATOR, ORIGINALASSIGNEEUSER, SUBSTATE from WFTASK where identificationkey = <request key>

  • How to see the change logs for billing document

    Dears,
    Could you please how to see the change logs for billing document.
    My client is using ECC 6.0 & if i use VF03 > Environment > changes > does not show the changes i had made.
    Thanks in advance
    Ranjan

    hello, friend.
    you should be able to see changes done after the initial creation and saving, by going thru Environment > Changes.  try it again, and this time make sure that changes were done to the billing document prior to posting to accounting.
    normally, when configuration of Billing is done correctly, there will be little or no instances of changing anything in the Billing document,  as saving the document after creation will post this to Accounting.  of course, inclusion of a posting block in the billing type will provide you the opportunity for changes. 
    regards.

  • How to get the link of already archived document

    Dear all,
    How to get the link of already archivied document. for example i have a sales order for which subsequent documents have been archived. now i want to get the link of subsequent document.
    please give some solution
    Thanks in advance
    Thanks,
    Hemachandran.

    Hemachandran,
                The archiving object for sales order is SD_VBAK. If you run the program S3VBAKAU by transaction se38 and search based on the document numbers ( as you mentioned it is the preceeding document numbers to the current document), you will be able to retrieve the information regarding the previous sales orders.
    More information on the sales order archiving object can be found at,
    http://help.sap.com/saphelp_45b/helpdata/en/a9/55c7b690a111d1a5510000e82deaaa/content.htm
    Sojan
    <<text removed by moderator>>
    Edited by: Matt on Nov 16, 2008 5:08 PM - Do not request points

  • How to upload the data to SAP-DMS(Document Management System)

    Dear sir,
    How to upload the data to SAP-DMS (Document Management System) please give me the code for this .ex for (excel format or tab  deliminated) to sap system through BAPI i have to pass.
    regards
    R M Patil

    Hi,
    May be following link may help you.
    /thread/315373 [original link is broken]
    /message/205534#205534 [original link is broken]
    Thanks,
    Sree.

Maybe you are looking for

  • Dunning Letter Email for all customers

    Hi All, I need your help in my requirement, which goes like this :- In F150 tcode(ecc 6.0), which internally uses RFMAHN20 program to display all customer accounts, we can select a customer and see the dunning letter(It's a sapscript) and also take a

  • ICloud Storage and Macbook

    Hello Everyone, If I delete old emails from my iCloud account, will they be deleted from Mail on my Macbook? I want to free up space on the cloud, but I don't want to permanently delete any of my e-mails, so hence, I want to keep them on my Macbook.

  • Which do you prefer: Increasing exposure or adjusting  the tone curve?

    I'd like to know how people here handle their images. I use a Nikon D7100 in camera RAW. In camera my images are always in balance. In LR, if I select Auto Tone in Basics invariably it will adjust the exposure. I tend to adjust exposure near last in

  • Long-touch selection of text suddenly stopped working, to highlight text. Any help?

    Last week I was using the long-touch method of selecting text. After selecting what I wanted I could choose to highlight that ext or strike through or all sorts if things. I can still use the highlight tool but the way I did it was so much nicer. Als

  • IOS8.1 does not recover from soft reset on iPhone 6

    My iPhone 6 does not recover from a soft reset (holding the home and power key until you see the apple).  It stays in the white screen with the black apple and never returns.  The reset was necessary due to a profile change request. What is the solut