About RegularExpression replace \1

Just starting out? Need help? Post your questions and find answers here.
shu7734
User
User
Posts: 30
Joined: Thu May 15, 2008 5:53 am

About RegularExpression replace \1

Post by shu7734 »

a.s="fsvFfs123fkasdjfk467566"
CreateRegularExpression(0,"(Ffs)(\d)")
ReplaceRegularExpression(0,a.s,"\1")

i want the result is

Ffs123

cann't suport \1\2 ?

example

Code: Select all

 
 If CreateRegularExpression(0, "(abC)(.+)")
    Result$ = ReplaceRegularExpression(0, "abC ABc zbA abc", "\1")
    Debug Result$ ; Will print "--- ABc --- abc"
  Else
    Debug RegularExpressionError()
  EndIf
i want debug output
abC
Win7X64 Purebasic5.22x86DEMO