Find RegEx within string

19 views
Skip to first unread message

Jose Adriano Baltieri

unread,
Feb 8, 2026, 6:17:44 AM (12 days ago) Feb 8
to sem...@googlegroups.com
Hi !

I'm trying this simple StrFind, which by the way is an example of the StrFind documentation (attached) and it returns ZERO ...

What's wrong with it, please ?

My version is also attached..


--


Grato,
Jose Adriano Baltieri

TEST229.S
StrFind_docs.jpg
TSE_VERSION.jpg

Carlo Hogeveen

unread,
Feb 8, 2026, 7:04:04 AM (12 days ago) Feb 8
to sem...@googlegroups.com

In your StrFind() command you reversed the order of the needle and the haystack.

Carlo



Jose Adriano Baltieri

unread,
Feb 8, 2026, 7:10:04 AM (12 days ago) Feb 8
to sem...@googlegroups.com
Thank U !

So silly ! Ashamed ! 

Thanks again !


On Sun, Feb 8, 2026 at 9:04 AM Carlo Hogeveen <t...@ecarlo.nl> wrote:

In your StrFind() command you reversed the order of the needle and the haystack.

Carlo



--

---
You received this message because you are subscribed to the Google Groups "SemWare TSE Pro text editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to semware+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/semware/000201dc98f3%24024d5690%2406e803b0%24%40ecarlo.nl.

Jose Adriano Baltieri

unread,
Feb 8, 2026, 7:15:38 AM (12 days ago) Feb 8
to sem...@googlegroups.com


We need to fix documentation ... The example there is wrong...



On Sun, Feb 8, 2026 at 9:04 AM Carlo Hogeveen <t...@ecarlo.nl> wrote:

In your StrFind() command you reversed the order of the needle and the haystack.

Carlo



--

---
You received this message because you are subscribed to the Google Groups "SemWare TSE Pro text editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email to semware+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/semware/000201dc98f3%24024d5690%2406e803b0%24%40ecarlo.nl.

knud van eeden

unread,
Feb 8, 2026, 7:44:03 PM (11 days ago) Feb 8
to sem...@googlegroups.com
FYIO

1. I noticed it already long time ago that the order needle/haystack was not working and after some tests concluded:

The correct order should thus be very easy to remember: 

You search for the

 'needle' in the 'haystack'

(and of course you do not search for the 

 'haystack' in the 'needle'

So there you have it.

2. My workaround is to define TSE templates (ending with a dot '.')

e.g.

 the TSE template
  st. 
   expands to 
    StrFind( "<search>", "<contain>", "^biwx$" )

 the TSE template 
  str. 
   expands to 
    StrReplace( "<old>", "<contain>", "<new>", "^biwx<any number>$" ) // tags {} are not possible

and so on...

with friendly greetings
Knud van Eeden
   






S.E. Mitchell

unread,
Feb 12, 2026, 5:39:55 AM (8 days ago) Feb 12
to sem...@googlegroups.com
I've made a note to fix the strfind() example.
> To view this discussion visit https://groups.google.com/d/msgid/semware/996432767.339792.1770597837663%40mail.yahoo.com.
Reply all
Reply to author
Forward
0 new messages