title: Set subreport text object in Crystal Reports
body: <p>I wanted to set the subreport header text via resource file.This the code i have tried below</p>
  
  <pre><code>  ReportDocument rDocument = (ReportDocument)Session["ReportSource"];
  
   ((TextObject)rDocument.Subreports["HolidaySubReport"].ReportDefinition.
   ReportObjects["HolidaySchedule"]).Text=Resources.Resources.HolidaySchedule;
  </code></pre>
  
  <p>But here i am getting error as <code>object reference not set to instance of object</code></p>
  
  <p>How can i solve this issue.Any help would be appreciated.</p>