Page 1 of 1

Automatically add references to report

Posted: Fri Feb 11, 2011 10:01 am
by marceljansen
Is there a way to automatically add assembly references to a report using the StiReport class?

Automatically add references to report

Posted: Mon Feb 14, 2011 2:19 am
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.