c# getting word before special character including whitespace or no whitespace : i have a string eg: string text = "select * from value='value' and testvalue = ?test and status like ?status";
i have tried using regular expression
   var m = Regex.Matches(str, @"(\S+)\s+=");//with whitespace
   var m = Regex.Matches(str, @"(\S+)=");//without whitespace

i need to get my output in dynamic labels and textbox
output:
label             textbox
testvalue 
status           

here in this string if already value present i dodnt want it as labels and textbox
only with question mark and like must give me output as mentioned above
if whitespaces present between '=', it must dicsard and give output