title: access private method in a different assembly c#
body: <p>This may be a daft question as I can see the security reason for it to happen the way it does...</p>
  
  <p>I have a licensing c# project, this has a class which has a method which generates my license keys. I have made this method private as I do not want anybody else to be able to call my method for obvious reasons</p>
  
  <p>The next thing I want to do is to have my user interface, which is in another c# project which is referencing the licensing dll to be the only other 'thing' which can access this method outside of itself, is this possible or do i need to move it into the same project so that it all compiles to the same dll and I can access its members?</p>
  
  <blockquote>
    <p>LicensingProject<br/>
    -LicensingClass<br/>
    --Private MethodX (GeneratesLicenseKeys) <br/></p>
    
    <p>LicensingProject.UI<br/>
    -LicensingUiClass<br/>
    --I want to be able to be the only class to be able to access MethodX</p>
  </blockquote>
  
  <p>There is a reason why the license Key Generator is not just in the UI, that is because the licensing works by generating a hash on itself and compares it to the one generated by the License Generator.</p>
  
  <p>I would prefer not to all compile to the dll as my end users do not need the UI code.</p>
  
  <p>I know that by common sense a private method, is just that. I am stumped.</p>