title: How can I create an Delphi object from a class reference and ensure constructor execution?
body: <p>How can I create an instance of an object using a class reference, and 
  ensure that the constructor is executed?</p>
  
  <p>In this code example, the constructor of TMyClass will not be called:</p>
  
  <pre><code>type
     TMyClass = class(TObject)
       MyStrings: TStrings;
       constructor Create; virtual;
     end;
  
  constructor TMyClass.Create;
  begin
     MyStrings := TStringList.Create;
  end;
  
  procedure Test;
  var
     Clazz: TClass;
     Instance: TObject;
  begin
     Clazz := TMyClass;
     Instance := Clazz.Create;
  end;
  </code></pre>