AddScriptReference does not work


01-21-2010, 7:00 PM
I use AddScriptReference in my code to import a dll and use personal functions, but it does not work to me.

I code this in C#:
ActiveReport report = new ActiveReport();

report.AddScriptReference("Functions.dll");

report.LoadLayout(layout);

arDesigner.Report = report;

and this in the report Script.

public void ActiveReport_ReportStart()
{
Functions.Class f = new Functions.Class();

((TextBox)rpt.Sections["Detail1"].Controls["TextBox1"]).Text = f.returnString();
}

The file Test is a simple test but it does not work

Please run EndUserDesigner.VS2k5.sln

Re: AddScriptReference does not work


01-22-2010, 9:37 AM
Hello,

The issue which you are experiencing is actually a known issue. There is already a Case 140909 opened to address this issue. I have added your E-mail address to the list of affected users for this case. Do let me know if you need further assistance/clarification.

Regards,
Ankit Nigam

Re: AddScriptReference does not work


01-25-2010, 9:56 AM
There is a way to make it work or a workaround??

Where can I check the Case 140909??

Thanks for the reply.

Re: AddScriptReference does not work


01-25-2010, 12:08 PM
Hello,

Unfortunately I do not have a workaround for this issue currently. If I get any, I will send you immediately.

About the case, I would like to inform you that your email address has already been added to the affected list, therefore you will be notified as soon as it gets fixed.

Regards,
Subodh

Re: AddScriptReference does not work


03-31-2011, 6:32 AM
The AddScriptReference() method takes a string that contains a file path eg.
report.AddScriptReference("C:\ApplicationFolder\Functions.dll");
If your DLL is in the same folder as your app this might work
report.AddScriptReference(AppDomain.CurrentDomain.BaseDirectory + "Functions.dll");
Hope this works!