I want to extract only those words between two commas. So, if the string is Ab Java, DE, 78801 The answer must be DE I have tried this code but it is not working
string search = "Ab Java, DE, 78801 ";
int index = search.IndexOf(",");
string result = search.Substring(search.IndexOf(",") ,index);
MessageBox.Show(result);