public static bool TryParseDictionaryFieldName(string fieldName, out string propertyName, out string dictionaryKey) { var match = _dictionaryFieldNameRegex.Match(fieldName); if (match.Success) { propertyName = match.Groups["prop"].Value; dictionaryKey = match.Groups["key"].Value; return true; } else { propertyName = null; dictionaryKey = null; return false; } }