-2

Can anyone help to get a regex build for below input string,I need to extract the the data which is marked . Eg:-

Input text:-

☐I am good
☐This is sky
☒Nice to meet you
☐hello world

Output :- Nice to meet you

Wiktor Stribiżew
  • 484,719
  • 26
  • 302
  • 397

1 Answers1

0

Just use

^☒.+

See a demo on regex101.com.


If you happen to have it in one line, you may use
☒[^☐\n]+

See another demo on regex101.com.

Jan
  • 38,539
  • 8
  • 41
  • 69