title: Passing null to `XslCompiledTransform.Transform` method
body: <p>I am trying to transform and XML document using XSL. I am not too familiar with how to transform XML in .NET so I am using some example code ...</p>
  
  <pre><code>XslCompiledTransform xslTransformer = new XslCompiledTransform();
  xslTransformer.Load(Server.MapPath("Test.xslt"));
  
  MemoryStream ms = new MemoryStream();
  xslTransformer.Transform(Server.MapPath("Test.xml"), null, ms);
  
  ms.Seek(0, SeekOrigin.Begin);
  StreamReader sr = new StreamReader(ms);
  string output = sr.ReadToEnd();
  ms.Close();
  
  Response.Write(output); 
  </code></pre>
  
  <p>The problem I am running into is the following line ...</p>
  
  <pre><code>xslTransformer.Transform(Server.MapPath("Test.xml"), null, ms);
  </code></pre>
  
  <p>The compiler is showing an error in passing in <code>null</code> to the Transform method. In looking at the <code>Transform</code> method signatures it looks like the parameter <code>null</code> is representing is various options for the transformation. The Visual Studio IDE even shows that this value can be <code>null</code>. I also tried using <code>DBNull.Value</code> but that also shows an error. Any idea what I am missing?</p>
  
  <p>UPDATE: The error I am receiving is two-fold. (1) First I am told that <code>null</code> is no longer supported and I should use <code>System.DBNull</code>. (2) Once I change <code>null</code> to <code>System.DBNull</code> I get an error saying <code>overload resolution failed because no accessible Transform can be called with these arguments.</code></p>