[AccessD] How to Change CRCRLF to just CRLF

Brad Marks BradM at blackforestltd.com
Fri Aug 2 15:01:34 CDT 2013


Thanks to everyone who helped me with this problem.

I appreciate the assistance.

Brad

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Stephen Bond
Sent: Thursday, August 01, 2013 5:45 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] How to Change CRCRLF to just CRLF

Brad,

This <<Replace("112","11","1")>> gives <<12>> in Access.  
Make the appropriate substitutions.

Stephen Bond


-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Brad Marks
Sent: Friday, 2 August 2013 10:31 a.m.
To: Stephen
Subject: [AccessD] How to Change CRCRLF to just CRLF

All,

We have an Access-based system that pulls records via ODBC from a
purchased Accounting system in order to generate EDI transactions.

For over three years, everything has worked nicely.

Today, one of the generated EDI transactions failed.  In looking at the
records pulled from the Accounting system, it appears that a small
number of the records end with CRCRLF instead of just CRLF (Carriage
Return Line Feed).

I can change the CR (Hex od) to spaces with a replace command like this

Str_A = Replace(Str_A, Chr(13), " ")


However, I don't want to replace all CRs with spaces.  I only want to
replace the first CR with spaces when I find CRCRLF.

Is there a way to do this with VBA?

Thanks,
Brad

--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

--
This message was scanned by ESVA and is believed to be clean.
Click here to report this message as spam. 
http://h0stname/cgi-bin/learn-msg.cgi?id=58DD928960.490AF





More information about the AccessD mailing list