Regex with Chinese characters

When I use a regular expression with a syntax “\p{Han}+”, it show me an error as below

Write line : parsing “\p{Han}” - Unknown property ‘Han’.

How can UiPath do a unicode filtering?


One two three four 一二三四

The regex should match the chinese characters only

1 Like

Try, [\p{Lo}]+

where \p{Lo} … matches letters without case

[\p{Lo}{Han}]+ This should work. refer test.xaml (5.8 KB)

Thanks, but this is not the ideal way to retrieve the value, as the capture group will be different. I saw you used output(2).toString for this checking. When I changed the others sentence
(such as “This is a company 一二三四”), the capture group will be different

[\p{Lo}\p{S}]+ Try with this code .
Refer the link.

It works. Thanks

1 Like