Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Import raw EDI files into Word and unwrap?

Status
Not open for further replies.

EDIOPS

Technical User
Dec 22, 2003
3
US
Is it possible to import raw EDI files and unwrap them [insert CR at end of segment] so the file is a bit more readable? If so, can someone tell me how?
Thanks!
 
Try using UltraEdit - view the file in Hex mode - Find/Replace Segment delimiter w/ 0D0A (carriage return - line feed)
I'm only familiar w/ UltraEdit for this method of file conversion but I'm sure others have other suggestions.

Good Luck!
 
I have downloaded it from Tucows and will try it out. I know there is a way to accomplish this in Word though - have seen it done but don't know how to set it up myself. I was hoping someone would job my memory..
Thanks for replying!

[santa3]
 
If you open the file in MS Word you can perform a "replace all" on the segment terminator (usually ' [single quote]) character with '^p which will place a carriage return after the single quote. You will need to use MS Notepad or another viewer to view the file to avoid the segments wrapping round. Hope this helps.




 
Hi...
I actually wrote a small program to do that... But I also use TextPad (shareware) as well as UltraEdit (30 days, but my company paid to use that)
I actually prefer to use the pattern matching feature so that I can view it in readable ascii while you work
To use Ultra Edit select the character that you wish to replace with CR/LF then
1.) Ctrl-R or select Replace from the Menu
2.) check Regular Expressions
3.) in the Find what box should be the character, sometimes it will look like a blacked out non character
4.) in the Replace with put in this two characters ^p
(that is the metacharacter(?) for carraige return)

Also as an extra hint, if you have multiple documents envelopes from different partners you can do this....
Replace: ISA
With: ^pISA
Be sure to be aware that regular expressions is on the next time! This is a problem if you use *, you would have to know to use ^* because * is a wildcard character.... such that "P[a-z]*l is cool" matches "Paul is cool" and "Paaaaaaaaaaal is cool"

With Textpad, it is easy as well, but it uses the UNIX style of pattern matching, which I prefer.
Select the character in question, run replace from the menu or press F8, check regular expression on and replace with \n

The help menu for either of these programs will give you some more info...
Hey but if you want to buy a copy the program that I wrote... :p
 
Thanks to all who replied with suggestions! I found that using UltraEdit in Hex mode and replacing segment delimiter with CRLF was quickest and easiest way for me - at least for this particular problem. We do use Textpad here, which usually works better for our translated flat files than the raw EDI files. I will definitely keep the other ideas in mind for future use though!
 
I saw a product that is FREE in the edi-l mailing list it is by talsystems recently.

Here is the url for EDI-L mailing list.

groups.yahoo.com/group/edi-l

you search for talsystems it should be there in the Jan 04 archive.

HTH.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top