Last time I had to do this I think I had a nested strtran to replace 3
spaces with 1 space  and then 2 spaces with 1 space.
I'm fairly sure that did the trick.

G


-----Original Message-----
From: [email protected] [mailto:[email protected]] On
Behalf Of Jack Skelley
Sent: 24 January 2011 22:01
To: GrahamB
Subject: Multiple Space Replacement

Good Afternoon:
I am trying to take text from a Word doc and put it into a memo field.
But what is happening is the unjustified text in Word doc is putting
multiple spaces between the words in the memo field where there is a
line feed from the Word doc.
I have a method I wrote years ago to remove the multiple spaces but
don't want to use it because it is in a loop. 
I half way remember someone posted a function to do this. But can't find
it.
I tried stuff() and strtran() but can't get it right because of the
variable number of spaces between 1 line to the next.
Does anyone remember the function to strip a variable number of spaces
into 1 space? Or was I dreaming?
Thanks!
Regards,

Jack Skelley
<a href="http://devils.nhl.com/";><IMG
SRC=http://c1.newjerseydevils.com/sig/signatures.php?sender=JSkelley@new
jerseydevils.com border="0" usemap="#Map"></a> <map name="Map">
  <area shape="rect" coords="4,67,203,85"
href="http://devils.nhl.com/club/page.htm?id=65573"; target="_blank">
  <area shape="rect" coords="269,67,346,87"
href="http://www.prucenter.com/"; target="_blank">
  <area shape="rect" coords="243,43,264,62"
href="http://www.youtube.com/prudentialcenter"; target="_blank">
  <area shape="rect" coords="223,43,244,62"
href="http://twitter.com/nhldevils"; target="_blank"><area shape="rect"
coords="203,43,224,62"
href="http://www.facebook.com/NewJerseyDevils?ref=ts"; target="_blank">
</map> </A>


[excessive quoting removed by server]

_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/[email protected]
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to