title: To delete all folders in the current directory with pattern matching
body: <p>I need to delete all the folders in current directory that starts with say "foo" followed by date<br>
  for example we have     </p>
  
  <ol>
  <li>foo20120620     </li>
  <li>foo20120513     </li>
  <li>fooblabla     </li>
  </ol>
  
  <p>I can successfully delete one folder that matches current date<br>
   example</p>
  
  <pre><code>set FOO_FOLDER=%CD%\foo%datetimef%      
  
  echo Y | rd /s/q %FOO_FOLDER%     
  </code></pre>
  
  <p>But I'm not able to delete all the folders starting with foo.</p>
  
  <p>I have been tried something like     </p>
  
  <pre><code>set OLD_PATTERN="%CD%\foo"     
  del %OLD_PATTERN%*
  </code></pre>
  
  <p>I have googled and tried to follow some questions already being asked in this forum , but those doesn't help me a lot.       </p>
  
  <p>Any  suggestion will be  of great  help to me.<br>
  must be in batch scripting on windows side.     </p>