title: How to split path to set of Path
body: <p>I have one path variable like 'Customer\\Calls\\A1\\A2\\A3\\A4'.From this i want split it into an array like </p>
  
  <pre><code>'Customer'
  'Customer\Calls'
  'Customer\Calls\A1'
  'Customer\Calls\A1\A2'
  'Customer\Calls\A1\A2\A3'
  'Customer\Calls\A1\A2\A3\A4'
  </code></pre>
  
  <p>If we do it like </p>
  
  <pre><code> string[] directories = currentFolderPath.Split(Path.DirectorySeparatorChar);
  </code></pre>
  
  <p>we will get a set of folder,but it will not get in above structure</p>
  
  <p>Can anyone suggest a better approach</p>