- This topic has 15 replies, 3 voices, and was last updated 3 years, 2 months ago by .
-
Topic
-
Good afternoon! I’m working on an interface to process PDFs, base64 encode and HL7-embed that information and I’m running into issues. On Cloverleaf 6.1.4.
VisualCron can drop a PDF file to Cloverleaf for me, and I want to use a fileset-local inbound to parse the PDF, pull the file name (which will have the patient identifier like V0000011.pdf,) base64-encode the PDF and pass both that encoded string and the file name to an xlate that would build an ORU, using SQL queries to grab more data on the patient and drop the encoded PDF string into OBX.5.
I’ve written a dirParse tcl to process only PDF files and an archive tcl to copy the PDF off to an archive as needed. I have a TPS to encode the PDF and pass that and the file name forward to the xlate. Then I have the xlate on a route between the fileset-local and another file thread (just for testing for now) with a VRL inbound and HL7 2.4 ORU outbound. The issue I’m having is that the data that is being passed from the fileset-local inbound is just thousands of characters, which I assume is the PDF being parsed as text, so I’m getting dozens of outbound ORUs with various strings in the OBX.5. Clearly I’m doing something wrong but I can’t for the life of me find anything on this forum that clearly indicates how to setup something like this.
I think I need to have the inbound tcl on the Trx ID Determination Format: UPOC instead of TPS Inbound Data but no matter what I do, I can’t get the filename from DRIVERCTL and I can’t get just the encoded PDF string and the filename sent forward to the xlate instead of all those random PDF characters. Any help would be appreciate and I can post some tcl if need be but it’s super rudimentary so I’m willing to start from scratch if needed. Thanks!
-Timothy
- You must be logged in to reply to this topic.