I would like to install a condition. I have already tried a lot but without success. Would someone be so kind and would help me?
My goal: if SharedKeys true then match elements(A B C D).
SharedKeys = "A","B","C","D"
Regex: (?!\")[A-Z]*?(?=\")
Match elements: A B C D
Update: (SharedKeys)?(?(1)|(?!\")[A-Z]*?(?=\"))
Match elements: SharedKeys A B C D
Link: https://regex101.com/r/WFxZh4/1
I think i have now what i needed, maybe helps others.
SharedKeys = "A","B","C","D"
BlaBla = "B", "B", "C"
Result: (SharedKeys|BlaBla)?(?(1)|(?!\")[A-Z]*?(?=\"))
Match elements: SharedKeys A B C D BlaBla B B C
Result for c++: [A-Za-z]+|(?!\")[A-Z]*?(?=\")
(std::regex)