web stats
Write pdf file in byte array to remote via sftp - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 07-29-2014, 02:04 PM
glennewing glennewing is offline
What's HL7?
 
Join Date: Apr 2012
Posts: 2
glennewing is on a distinguished road
Default Write pdf file in byte array to remote via sftp

I have been embedding BASE64 encoded PDF files in HL7 messages but now need to also write the PDF file to a remote computer using SFTP. I was hoping to use the File Writer to do this but for the life of this newbie I cant figure out how to correctly use the template to correctly write the byte array to the file. I know zero about Velocity. Any/all help will be greatly appreciated.

Connect version: 3.0.3.7171
Reply With Quote
  #2  
Old 07-29-2014, 03:12 PM
narupley's Avatar
narupley narupley is offline
Mirth Employee
 
Join Date: Oct 2010
Posts: 7,124
narupley is on a distinguished road
Default

Quote:
Originally Posted by glennewing View Post
I have been embedding BASE64 encoded PDF files in HL7 messages but now need to also write the PDF file to a remote computer using SFTP. I was hoping to use the File Writer to do this but for the life of this newbie I cant figure out how to correctly use the template to correctly write the byte array to the file. I know zero about Velocity. Any/all help will be greatly appreciated.

Connect version: 3.0.3.7171
Enable Binary mode on the File Writer, and then just drop the Base64-encoded string into the template.
__________________
Step 1: JAVA CACHE...DID YOU CLEAR ...wait, ding dong the witch is dead?

Nicholas Rupley
Work: 949-237-6069
Always include what Mirth Connect version you're working with. Also include (if applicable) the code you're using and full stacktraces for errors (use CODE tags). Posting your entire channel is helpful as well; make sure to scrub any PHI/passwords first.


- How do I foo?
- You just bar.
Reply With Quote
  #3  
Old 07-30-2014, 10:39 PM
glennewing glennewing is offline
What's HL7?
 
Join Date: Apr 2012
Posts: 2
glennewing is on a distinguished road
Default

Just what I needed. Thanks!
Reply With Quote
Reply

Tags
file writer, pdf, sftp

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 12:06 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Mirth Corporation