title: Compile a single CS project in a solution twice, one with a preprocessor constant defined and one without it
body: <p>The idea is mainly to make my service read-only (due to security reasons) by checking whether a preprocessor constant is defined or not. I will have</p>
  
  <pre><code>#if READONLY
          throw new NotImplementedException();
  #elseif
          //code implementation here
  #endif
  </code></pre>
  
  <p>in my implementation. I can pass or define the constant READONLY through msbuild parameters when I compile the solution.</p>
  
  <p>Now coming to the point, the issue I face is, I want the particular service implementation project to be compiled twice in a single compilation cycle, one with the constant defined and one without it. </p>
  
  <p>Welcome any help.</p>