How to get left and right of character?

Input: 28 February 2022 at 07:50
Ouput: 28 February 2022 07:50

Need Regex expression for this, i dont want to use any replace function into it…

Wanna do this completely using Regex

Hi @NervousTuber ,

Is this what you were looking for?
image

MatchExercise.xaml (4.9 KB)

String.Join("",System.Text.RegularExpressions.Regex.Matches("28 February 2022 at 07:50","(?<=at).*|.*(?=at)").Cast(Of Match).Select(Function(s) s.ToString))

Kind Regards,
Ashwin A.K

Thanks its working

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.