One option is to bring the Date string into the standard format Date string and then to use DateTime.ParseExact method
static void Main(string[] args) {
string datePattern = @"(\d{4})-(\d{1,2})-(\d{1,2})T(\d{1,2}):(\d{1,2})";
string dateString = "2012-3-27T6:30";
Match dateMatch = Regex.Match(dateString, datePattern);
string spacers = "00--T:";
if (dateMatch.Success && dateMatch.Groups.Count==6) {
string formattedDateString = dateMatch.Groups[1].Value;
for (int i = 2; i < dateMatch.Groups.Count; i++) {
formattedDateString += spacers[i] + dateMatch.Groups[i].Value.PadLeft(2, '0');
}
var dt = new DateTime(int.Parse(dateMatch.Groups[1].Value),
int.Parse(dateMatch.Groups[2].Value),
int.Parse(dateMatch.Groups[3].Value),
int.Parse(dateMatch.Groups[4].Value),
int.Parse(dateMatch.Groups[5].Value), 0);
Console.WriteLine(formattedDateString);
Console.Write(dt);
Console.ReadKey();
}
}