Automatically add references to report

Stimulsoft Reports.NET discussion
Post Reply
marceljansen
Posts: 2
Joined: Tue Feb 08, 2011 5:56 am
Location: Netherlands

Automatically add references to report

Post by marceljansen »

Is there a way to automatically add assembly references to a report using the StiReport class?
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Automatically add references to report

Post by Alex K. »

Hello,

You can use the following code:

Code: Select all

StiReport report = new StiReport();
string[] newRefAsssemblies = new string[9] 
 { "System.Dll", "System.Drawing.Dll", "System.Windows.Forms.Dll", "System.Data.Dll", "System.Xml.Dll", "Stimulsoft.Controls.Dll",
    "Stimulsoft.Base.Dll", "Stimulsoft.Report.Dll", "MyReference.dll"};
report.ReferencedAssemblies = newRefAsssemblies;
report.Design();
Thank you.
Post Reply