6 Replies Latest reply: Feb 15, 2013 12:46 PM by Srini Chavali-Oracle RSS

    Customize Output of the PO Output for Communication program R12

      I have a requirement to change the output of the seeded PO Output for Communication program, so that it uses a custom RTF template to produce the documents.

      To do this, I have registered this template in XML Publisher under the Purchasing application. I then navigated to Purchasing Super User > Setup > Purchasing > Document Types, and from the window opened, selected to update the Purchase Order Standard Type. From here, I updated the document name and the document type layout as my new custom template.

      However, once I run the program, it completes with an error. The log file is pages and pages (that I won’t post here unless requested as necessary) but at the bottom is section produced that I think may be useful:

      Updated PRINT_COUNT 1
      doc Identifier: PO
      Document ID:14004
      Revision Num0
      Document SubTypeSTANDARD
      Document TypePO
      GenerateDocument::2nd Constructor()
      setFileName- m_documentType:PO, m_documentId:14004
      setFileName- m_fileName:PO_84_700000049_0_US.pdf
      GenerateDocument::Finished 3rd Constructor()
      Setting PO template Code
      Setting OKC template Code
      Before calling genDocTue Jan 22 17:02:01 GMT 2013
      Changed GenerateDocument::Inside the gendoc method
      Calling the getDocument method
      GenerateDocument::getDocument()- Set the Org Context
      GenerateDocument::getDocument() - Searching in the repository
      After Calling the getDocument method
      Calling the getPOXsl method
      Before setting the bind variables for the default layout in getPOXSL()
      Document Template Code :NCC_STD_PO_RTF
      Language Code :US
      Document XSL Contents Tue Jan 22 17:02:01 GMT 2013
      Retrieved the Document XSL Tue Jan 22 17:02:01 GMT 2013
      Calling the getPOXml method
      GenerateDocument::getPOXml() : l_exists 1
      GenerateDocument::getPOXml() : m_whichTables MAIN
      GenerateDocument::getPOXml()- Calling the POXMLGEN method Tue Jan 22 17:02:01 GMT 2013
      Generated the Document XML Tue Jan 22 17:02:01 GMT 2013
      Document XML Contents Tue Jan 22 17:02:01 GMT 2013
      Calling the print util method:Tue Jan 22 17:02:01 GMT 2013
      Passing Params to getBlobPDF :Tue Jan 22 17:02:01 GMT 2013
      m_AppNames :PO
      m_TemplateCodes :NCC_STD_PO_RTF
      m_Languages :en
      m_Territories :US
      genDoc() : Exceptionjava.lang.Exception: Error while generating PDF :null
      java.lang.Exception: Error while generating PDF :null
      rolling back the complete program

      As you can see it's definitely picking up my custom template (NCC_STD_PO_RTF), and it appears to error when tryign to generate it as PDF.

      I have attempted to attach the seeded xsl template to my template definition - to test if the error is due to the program expecting a certain template format - but, as the seeded template is in that particular format, and my definition is expecting rdf, it will not let me.

      I am wondering if anyone has a solution for this requirement. We would like to keep the business process the same as it was in 11i, by using the seeded program, but with a custom template. But I understand that in R12, creating a custom program replicated from the seeded may be the only viable solution.

      This is on Oracle Applications version 12.1.3.

      Any suggestions would be much appreciated, and if you think that any more information is required, let me know.