From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Regex Question

Solved!
Go to solution

One day, I will learn Regex. However, that day has not yet arrived. All I need to do is pick out the string between to brackets [abcde] returns abcde. I thought it would be something like \[(.+)\] but I can't get it to work in LabVIEW. Suggestions?

0 Kudos
Message 1 of 3
(2,255 Views)
Solution
Accepted by topic author GregFreeman

You have the right regular expression. Here is the code I tested. (The constants represent the values in the controls and indicators)

 

Regex to pick value in brackets.png



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 2 of 3
(2,249 Views)

AH! I didn't look at the submatch

0 Kudos
Message 3 of 3
(2,236 Views)