Regular Expression to get text between words separated with line break
-
I need to get the text between two words but both the words are in different line using regular expression in vb script.
For Example,
str = “Hello World
Information Address 908 BLVD
Avenue Property Type Occupied”I need “908 BLVD Avenue” using regex.So my regex pattern must be anything between “Address” and “Property Type”. Till now , I could able to find “908 BLVD” using
(?<=Address)(.*)\s
but unable to get text before Property Type in same regex function.Thanks
-
(?s)(?<=Address\x20).*(?=\x20Property\x20Type)
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login