Subject: | |
From: | |
Reply To: | |
Date: | Thu, 29 Jan 1998 11:10:41 -0500 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
Kevin,
Here's a CI command file to do what you want. It's not very
efficient and a record containing a doube quote (") will screw it up. It
will copy from the old file containing the CR/LF and write to a new
temporary file.
Execute it like this;
StripCR NewFile < OldFile
StripCr Command File follows
------------------------------------------
Parm NewFile
Continue
Purge !NewFile,Temp > $Null
While True
ErrClear
Continue
Input Name=Buffer > $Null
if CIError<>0 Then
Return
Endif
SetVar n Pos(Chr(13),"!Buffer")
If n>0 Then
SetVar n n - 1
SetVar Buffer Str("!Buffer",1,n)
EndIf
Echo !Buffer >> !NewFile
EndWhile
Hope this works for you
John Zoltak
North American Mfg Co
> -----Original Message-----
> From: Kevin J. Mullins [SMTP:[log in to unmask]]
> Sent: Wednesday, January 28, 1998 1:10 PM
> To: [log in to unmask]
> Subject: [HP3000-L] Stripping CR/LF characters in ASCII file
>
> We have an ASCII file that contains a carriage return and line feed
> character as a delimiter at the end of the data contained in each
> record
> following by trailing spaces to fill out the record.
>
> Looking for an easy way to strip out these two characters from each
> record.
> Was hoping to use EDITOR and MPEX to accomplish this but have not
> found a
> solution. Contacted VESOFT for possible answers but they did not
> manage to
> come up with anything within the past day.
>
> Any ideas how this can be done fairly simply? We could create a quick
> program to do this but really are looking for other options.
>
> Thanks in advance for any help anyone can offer.
> Kevin
> ***************************************************
> * Kevin J. Mullins Phone: 281-897-3626
> *
> * MIS Manager Fax: 281-469-3226
> *
> * Interconex,Inc. E-mail: [log in to unmask] *
> ***************************************************
|
|
|