Remove illegal characters
This commit is contained in:
parent
1dba5fcfa4
commit
f66393e27e
@ -325,13 +325,8 @@ public partial class ProcessData
|
|||||||
// Example: "Cassette 47-241330-4238 started."
|
// Example: "Cassette 47-241330-4238 started."
|
||||||
segments = line.Substring(9).Split(new string[] { "started" }, StringSplitOptions.RemoveEmptyEntries);
|
segments = line.Substring(9).Split(new string[] { "started" }, StringSplitOptions.RemoveEmptyEntries);
|
||||||
if (segments.Any())
|
if (segments.Any())
|
||||||
{
|
// Remove illegal characters \/:*?"<>| found in the Cassette.
|
||||||
// Detected a new cassette scan in the raw source file
|
cassetteID = Regex.Replace(segments[0].Trim(), @"[\\,\/,\:,\*,\?,\"",\<,\>,\|]", "_").Split('\r')[0].Split('\n')[0];
|
||||||
cassetteID = segments[0].Trim();
|
|
||||||
cassetteID = cassetteID.Replace(":", string.Empty);
|
|
||||||
cassetteID = cassetteID.Replace("*", string.Empty);
|
|
||||||
cassetteID = cassetteID.Replace("\\", string.Empty);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Continue reading and saving the cassette scan information, into the cassette
|
// Continue reading and saving the cassette scan information, into the cassette
|
||||||
|
Loading…
x
Reference in New Issue
Block a user