Extract Numeric values

public string[] ExtractNumbers(string str)
{
    // Find matches
    System.Text.RegularExpressions.MatchCollection matches
        = System.Text.RegularExpressions.Regex.Matches(str, @"(\d+\.?\d*|\.\d+)");

    string[] MatchList = new string[matches.Count];

    // add each match
    int c = 0;
    foreach (System.Text.RegularExpressions.Match match in matches)
    {
        MatchList[c] = match.ToString();
        c++;
    }

    return MatchList;
}