Menu

#440 Facing issue "Exception received: [java.util.MissingResourceException] PCML document source 'Resource/XYZ-rpgpgm/ABCD.pcml' cannot be found"

PCML
open
Zhang Ze
None
2
2022-03-01
2021-01-05
No

When I choose a PCML file, I can only set it if I browse the PCML file from the file system.
If I choose to set it from the workspace in eclipse, having it in the same project. When I try locating pcml file then getting an error that it cannot find the file.

"Exception received: [java.util.MissingResourceException] PCML document source 'Resource/XYZ-rpgpgm/ABCD.pcml' cannot be found"

We are using JT400 9.1 version.

1 Attachments

Discussion

  • Sharique Hussain

    Hi Zhang

    do we have any update on this ?

     
  • Sharique Hussain

    Hi Zhang,

    Any update on this ?

     
  • Kuldeep Singh Mathuria

    Hi Zhang,
    Could you please provide an update on this query.

     
  • Zhang Ze

    Zhang Ze - 2021-03-05

    hi, Can I get a sample code? How do you call the ProgramCallDocument with the pcml?

    This is an example, hope it's helpful.
    ProgramCallDocument pcml = new ProgramCallDocument(as400, testPCML);
    String testPCML = "com.ibm.as400.pcml.test.test.pcml";

     
  • Zhang Ze

    Zhang Ze - 2021-03-09

    In my example, the pcml file name is test.pcml. FYI

     
  • Sharique Hussain

    Hi Zhang,
    Please read the attached word document "Context"for more information on the issue we are facing. Also, please find below lines of code :

    if (model instanceof ProgramCall && ((AbstractProgramObject) section.getInput())
    .isPCMLEnabled()){

    String pcmlFile = ((ProgramCall) section.getInput()).getPCMLFile();
    
    
    Descriptor pcmlDescriptor = ProgramCallDocument.getDescriptor(pcmlFile, new Pcml_CustomClassLoader(), null);
    
    
    String pcmlProgramName =((ProgramCall) section.getInput()).getPCMLProgramName();
    
    Enumeration<Descriptor> program_enumeration= pcmlDescriptor.getChildren();
    
    SMetaClass sMetaClass= new SMetaClass();
    
    
                while(program_enumeration.hasMoreElements()){
                      Descriptor programDescriptor = program_enumeration.nextElement();
    
    
                        sMetaClass.setName(programDescriptor.getName());
    
     
  • Sharique Hussain

    Hi Zhang,

    Any update on this ?

     
  • Sharique Hussain

    Hi Zhang,

    Any update on this ?

     
  • Sharique Hussain

    Hi Zhang,

    Any update on this ?

     

Log in to post a comment.

MongoDB Logo MongoDB