Torna al Thread

string eml = File.ReadAllText("c:\\mia.eml"); string subject = string.Empty; Regex regex = new Regex("Subject:(.*)", RegexOptions.Multiline | RegexOptions.IgnorePatternWhitespace | RegexOptions.IgnoreCase); if (regex.IsMatch(eml)) subject = regex.Match(eml).Groups[0].Value;
Copyright © dotNetHell.it 2002-2024
Running on Windows Server 2008 R2 Standard, SQL Server 2012 & ASP.NET 3.5