View Single Post
  #18   Report Post  
Posted to microsoft.public.excel.misc
Ron Rosenfeld Ron Rosenfeld is offline
external usenet poster
 
Posts: 5,651
Default How to trim a string to the last "."

On Tue, 27 Nov 2007 18:50:17 -0500, Ron Rosenfeld
wrote:

On Tue, 27 Nov 2007 14:55:12 -0800 (PST), Bernd P wrote:

Hi Ron, hi Rick,

let us agree that regex are quite powerful. Since they are line-
orientated (or we are facing line restrictions) we can wait and see
whether my suggesion will work for the OP.

And now let us wait for the next two dozen questions regarding string
manipulation and let's count the overall sum of UDF rows plus calls to
them (it)...

Regards,
Bernd


Why do you write they are "line-oriented"?

At least in the few flavors with which I am familiar, multiline implementations
are common. The issue here is that with VBA, setting multiline to TRUE (which
is allowed in the UDF you recommended) only changes the behavior of "^" and
"$", and not the behavior of "." as is true for other flavors. Simple enough
to work around, though.
--ron


I really should have included the qualification that the original Unix editors,
and regex engines were, indeed, line oriented. However, when I first worked
with Unix (actually I think it was Xenix, if I recall correctly) back in the
early '80's, vi (a screen editor) had already been developed and was pretty
widely distributed.


--ron