Index: uc_edi.module
===================================================================
--- uc_edi.module	(revision 285)
+++ uc_edi.module	(working copy)
@@ -570,7 +570,7 @@
     $filepath = file_destination(file_create_path(file_directory_temp() .'/'. $filename), FILE_EXISTS_RENAME);
 
     // Create the file.
-    if (file_save_data($contents, $filepath)) {
+    if (file_save_data(html_entity_decode($contents, ENT_QUOTES, 'UTF-8'), $filepath)) {
       switch ($type) {
         case 'order':
           // Get a list of delivery methods.
