A few weeks back I documented an extension I built for a potential customer that passed a chunk of the XML tree out and passed back some formatted text.
Well I have another coming up, more of that later this week. One problem was how to test the extension in the template builder. It was a bit of a pain, having to merge the extension class and any supporting classes into an existing zip or jar that the builder knew about.
Today, I actually bothered to reach out to 'template builder meister' Junichi and ask if I could add a classpath command or in some way include my extension jar. Ask and you shall receive ... simple stuff, this communicating with people :0)
Just open RTF2PDF.jar under jlib directory, for me thats 'D:\Program Files\Oracle\BIP\BIP Desktop\Template Builder for Word\jlib'. You will see MANIFEST.MF file inside. Back up that files and then add a file path to class-path in the manifest file, the new jar/zip will be used when you run the preview.
The manifest file looks like this out of the box
Manifest-Version: 1.0 Class-Path: ./activation.jar ./mail.jar ./xdochartstyles.jar ./bicmn. jar ./jewt4.jar ./share.jar ./bipres.jar ./xdoparser.jar ./xdocore.ja r ./xmlparserv2.jar ./xmlparserv2-904.jar ./i18nAPI_v3.jar ./version info.jar Main-Class: RTF2PDF
With my extension and supporting library I now have
Manifest-Version: 1.0 Class-Path: ./activation.jar ./mail.jar ./xdochartstyles.jar ./bicmn. jar ./jewt4.jar ./share.jar ./bipres.jar ./xdoparser.jar ./xdocore.ja r ./xmlparserv2.jar ./xmlparserv2-904.jar ./i18nAPI_v3.jar ./version info.jar D:/Work/idauto/idfontextension.zip D:/Work/idauto/LinearBarCode.jar Main-Class: RTF2PDF
Update
Typo in the file above. you can only use relative folder references ie the file above will not work. I just dropped my jars and zips into the same jlib folder and used
Manifest-Version: 1.0 Class-Path: ./activation.jar ./mail.jar ./xdochartstyles.jar ./bicmn. jar ./jewt4.jar ./share.jar ./bipres.jar ./xdoparser.jar ./xdocore.ja r ./xmlparserv2.jar ./xmlparserv2-904.jar ./i18nAPI_v3.jar ./version info.jar ./idfontextension.zip ./LinearBarCode.jar Main-Class: RTF2PDF
as my file entry ... works great!
When I now hit preview for any of the formats supported my extension is pulled in without the need for all that merging.
If you are now wondering how I opened the RTF2PDF.jar file, I used winzip or zip or you could use the java tools.
Thanks for the tip Junichi. Big prizes for anyone guessing what my latest extension project has been. OK there's no prize but you'll get a mention :0)
Comments (3)
I might be late to respond to this one. The class path gives it away it's the barcode generation module from ID Automation. Incidentally, we use it heavily from Oracle Reports on Linux. And since we are contemplating a move to BIP Enterprise, the fact that you are testing this is good timing from my perspective.
Manish
Posted by Manish | July 7, 2009 7:14 AM
Posted on July 7, 2009 07:14
What am I to Think about Easter? ,
Posted by Faggot67 | October 22, 2009 4:10 AM
Posted on October 22, 2009 04:10
They have opened the job as a full-time position, which means my temp job will no longer exist and I have to apply for the full time one. ,
Posted by Gangster50 | October 23, 2009 3:21 AM
Posted on October 23, 2009 03:21