←  Technical Questions

nanoCAD forum

»

Regular expressions find an replace

sidi's Photo sidi 27 Feb 2017

Hi,
for the life of me I cannot replace text with modified matched pattern.
I'm trying to replace:
(\d+)
with:
AA $1

Tried to use $1, ($1), [0], $[0], item[0], Item[0] as suggested in regular expressions (Pattern) tool tip.
Quote

Hellen_V's Photo Hellen_V 27 Feb 2017

Hi,
explain your problem in detail, please.
Quote

SevaM's Photo SevaM 27 Feb 2017

Hi Sidi,

doesn't work for me too, it seems that "Replace with" doesn't process pattern-related obptions.
And in your case it will not works ( imho) at all - I didn't found anything how to recall not exactly definet string ( for eample 1 ), but current.

Will ask developer who wrote this dialog. In our local version this feature is marked "Not ready yet" - so, probably it will be finished in next version.

Best regards,
Seva.
Quote

sidi's Photo sidi 27 Feb 2017

View PostSevaM, on 27 February 2017 - 03:05 PM, said:

Hi Sidi,

doesn't work for me too, it seems that "Replace with" doesn't process pattern-related obptions.
And in your case it will not works ( imho) at all - I didn't found anything how to recall not exactly definet string ( for eample 1 ), but current.

Will ask developer who wrote this dialog. In our local version this feature is marked "Not ready yet" - so, probably it will be finished in next version.

Best regards,
Seva.

Thanks Seva. Not sure why you would put a tool tip for function that wasn't implemented, I'm using nanoCAD 5.

@Hellen V I'm trying to use "Find and replace" (ctrl+F) to edit selected MText objects with regex
Quote