title: C# - Splitting on a pipe with an escaped pipe in the data?
body: <p>I've got a pipe delimited file that I would like to split (I'm using C#). For example:</p>
  
  <pre>
  This|is|a|test
  </pre>
  
  <p>However, some of the data can contain a pipe in it. If it does, it will be escaped with a backslash:</p>
  
  <pre>
  This|is|a|pip\|ed|test (this is a pip|ed test)
  </pre>
  
  <p>I'm wondering if there is a regexp or some other method to split this apart on just the "pure" pipes (that is, pipes that have no backslash in front of them). My current method is to replace the escaped pipes with a custom bit of text, split on pipes, and then replace my custom text with a pipe. Not very elegant and I can't help but think there's a better way. Thanks for any help.</p>