on 12-18-2014 11:32 AM
Hello Experts,
Is there a way to generate an .ZIP file within a Step in B1if?
Basically I need to generata an ZIP file with documents created in B1if Step.
Thanks in advance.
Pierre
Thanks to Maria Trinidad from SAP I had what I want and I'm ready to share.
Here's how I made it work:
Here is my Processing Flow:
GetFile atom details:
the xform (atom2.xsl) transformation:
<xsl:template name="transform">
<bfa:io pltype="zip">
<bfa:zipentry
entryname="test.pdf" dataset="" group="" docname="" alias="" pltype="bin" properties="">
<xsl:copy-of select="/vpf:Msg/vpf:Body/vpf:Payload[./@id='atom3']/bfa:io" />
</bfa:zipentry>
</bfa:io>
</xsl:template>
StoreFile atom details:
et Voilà I've got a freshly new test0000.zip file containing test.pdf in my c:/tmp directory.
This scenario step is not performing like a flash because of bin to char conversion so use your precautions, anyway it did the work fine for me.
Thanks again Maria for helpful info, hope this can help.
Regards
Pierre
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pierre
You can use 'Call .NET' atom. For the newest B1iF version documentation says that you need to use > 4.0 version and it means that you can (most likely - I haven't tried it) take advantage of System.IO.Compression.ZipFile from .NET 4.5.
Check this:
c# - Create normal zip file programmatically - Stack Overflow
Kind regards,
Radek
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.