string AdmissionDiagnosispattern = @"入院诊断[\S\s]*(?=出院诊断)"; 取出来的是入院诊断xxx到出院诊断,但是不包括出院诊断这四个字 (?=)不包括! \s匹配空格或者tab等字符