title: VB.NET logical expression evaluator
body: <p>I need to test a logical expression held in a string to see if it evaluate to TRUE or FALSE.(the strig is built dynamically)<br>
  For example the resulting string may contain "'dog'&lt;'cat' OR (1>4 AND 4&lt;6)". There are no variables in the string, it will logically evaluate. It will only contain simple operators = > &lt; >&lt; >= &lt;= and AND , OR and Open and Close Brackets, string constants and numbers. (converted to correct syntax &amp;&amp; || etc.)</p>
  
  <p>I currently acheive this by creating a jscipt function and compiling it into a .dll. I then reference the .dll in my VB.NET project.</p>
  
  <pre><code>class ExpressionEvaluator  
  {  
    function Evaluate(Expression : String)  
    {  
      return eval(Expression);  
    }  
   }  
  </code></pre>
  
  <p>Is there a simpler method using built in .NET functions or Lamdba expressions.</p>