Telerik Forums
Reporting Forum
1 answer
129 views
Hi,

I've added two datasources to my report project. the first one is for the report itself, the second one for a chart.
Please see the code below.

<connectionStrings>
   <add name="ReportPlugin.Properties.Settings.Development"
connectionString="Data Source=*****;Initial Catalog=*****;Integrated Security=True"
       providerName="System.Data.SqlClient" />
 </connectionStrings>


//
// sqlDataSource1
//
this.sqlDataSource1.ConnectionString = "ReportPlugin.Properties.Settings.Development";
this.sqlDataSource1.Name = "sqlDataSource1";
this.sqlDataSource1.SelectCommand = resources.GetString("sqlDataSource1.SelectCommand");
//
// sqlDataSource2
//
this.sqlDataSource2.ConnectionString = "ReportPlugin.Properties.Settings.Development";
this.sqlDataSource2.Name = "sqlDataSource2";
this.sqlDataSource2.Parameters.AddRange(new Telerik.Reporting.SqlDataSourceParameter[] {
new Telerik.Reporting.SqlDataSourceParameter("country.id", System.Data.DbType.Int32, "=Parameters.CountryId.Value")});
this.sqlDataSource2.SelectCommand = resources.GetString("sqlDataSource2.SelectCommand");

private void chart1_NeedDataSource(object sender, EventArgs e)
{
    Telerik.Reporting.Processing.Chart chart = sender as Telerik.Reporting.Processing.Chart;
    chart.DataSource = sqlDataSource2;
}

The first datasource connects perfectly. The second doesn't. They make use of the same ConnectionString.
The error is:
An error has occurred while processing Chart 'chart1':
Unable to connect to database. Please verify that your connection string is valid; in case you use a connection string from the application configuration file, make sure the name is correct and the connection string settings are present in the configuration file of your application.

Any ideas?

Thnx,
Robert
Peter
Telerik team
 answered on 20 Jul 2010
1 answer
54 views
Hi,

I posted a question about how bars in a chart can be colored depending ion their value but it seems to have gone missing. Its URL was:

http://www.telerik.com/community/forums/reporting/telerik-reporting/specify-color-of-individual-bars.aspx

Has it been deleted for some reason? Shall I repost the question?

Thanks,
Jason
Steve
Telerik team
 answered on 16 Jul 2010
7 answers
220 views
I'm having a difficult time getting reporting to work with the Silverlight Report Viewer.

I've viewed the video you reference, and I'm at the point where I'm supposed to set the Report property on the Silverlight Report Viewer equal to the assembly qualified name of the report, but I haven't the slightest idea where I get that information.

In another post, you used the following example for the assembly qualified name, 'Report="Telerik.Reporting.Examples.CSharp.BarcodesReport, CSharp.ReportLibrary, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" '.

Where are these pieces of information coming from?

It would appear as if "CSharp.ReportLibrary" is the name of the class library containing the report, but what is "Telerik.Reporting.Examples.CSharp.BarcodesReport"?

In the video, he uses "Telerik.Reporting.Examples.CSharp.ProductCatalog", but never explains what this is or where it's from. It looks like it's a namespace, but when I put in the namespace I think I should be using it doesn't work.

Can you please break down where these pieces of information come from and how you get the information to include in your project?

Thank you.
Peter
Telerik team
 answered on 16 Jul 2010
1 answer
155 views
We're looking into replacing our very old (10 years+) ActiveReports reporting system with Telerik.  I have a general question which i have not seen in the documentation:
Can Telerik reports (now or in the next few versions) be created dynamically at run time?  
For example, say we store the layout, columns, groupings, filters, etc in our database, can we generate the full report layout at runtime?
Steve
Telerik team
 answered on 16 Jul 2010
4 answers
249 views

Hello,

     I am having some troubles building my first report with Telerik Reporting. I read the docs in order up to this point. I followed the "creating a simple report page" and it seems like all went well for building the library with one simple report. However, onto the next step, displaying the report in a report viewer in wpf does not work. First off, there is no dock property as shown in step 4. The bigger problem however, is setting the report property of the reportViewer.

Here is a code snippet:

     

Public Class ReportView


    Private Sub WindowLoaded(ByVal sender As System.Object, ByVal e As System.Windows.RoutedEventArgs) Handles MyBase.Loaded

Dim routeReport as New ReportingLibrary.RouteReport

        ReportViewer1.Report = routeReport

    End Sub

End Class



And here is the error that I get:

Set property 'System.Windows.ResourceDictionary.DeferrableContent' threw an exception.


RouteReport.vb is report that was created with the report wizard, and previews correctly. I checked the target framework  .NET Framework 4.0 (not the client profile). Any suggestions would be greatly appreciated.



Thanks in advance

Steve
Telerik team
 answered on 16 Jul 2010
2 answers
234 views
Hi,

I am using Report Viewer Version=3.2.9.1211.  The navigation tool bar on top of the report viewer is showing duplicate navigation buttons/images. I looked at the page source, it has both enabled and disable images for every button (Ex: PreviousPage). Please see the highlighted portion of the attached image files of the report viewr and page source.

Would appreciate quick response.

Thanks,
Mkr
LDev
Top achievements
Rank 1
 answered on 15 Jul 2010
1 answer
140 views
HI

I'm using Telerik Reporting 2010-Q2, and I have try to add the Telerik Silverlight report viewer to Mainpage.xaml (SilverLight4) and I get the error:

Error HRESULT E_FAIL has been returned from a call to a COM component.

at MS.Internal.XcpImports.MethodEx(IntPtr ptr, String name, CValue[] cvData) at MS.Internal.XcpImports.MethodPack(IntPtr objectPtr, String methodName, Object[] rawData) at MS.Internal.XcpImports.Collection_Add[T](PresentationFrameworkCollection`1 collection, Object value) at System.Windows.PresentationFrameworkCollection`1.AddImpl(Object value) at System.Windows.PresentationFrameworkCollection`1.System.Collections.IList.Add(Object value) at Microsoft.Expression.DesignModel.InstanceBuilders.ClrObjectInstanceBuilder.InstantiateChildren(IInstanceBuilderContext context, ViewNode viewNode, DocumentCompositeNode compositeNode, Boolean isNewInstance)



Is SL 4 supported??
Do you have an example SL4 Project??

Thanks!
Peter
Telerik team
 answered on 15 Jul 2010
3 answers
169 views
Hi,

Is there any way to have a fixed line on x and y axis in the point chart. Is it also possible to have 2 fixed lines in x and y axis in the point chart. Please find the requirement chart attached.

Thanks in advance.
Steve
Telerik team
 answered on 15 Jul 2010
1 answer
53 views
Is it possible to add paging to the bottom of the report viewer (along with having it at the top)?
Steve
Telerik team
 answered on 14 Jul 2010
5 answers
227 views
Hello everybody!

We are using Telerik Reporting in an ASP .NET Application.
We had some issues with the report not showing while fetching data, which led to the application seeming to not respond.
To overcome this issue we initialized the report at first with no data (i.e. Report Parameters not set) and placed an ASP Update Panel and ASP Timer.
In the Tick event of the Timer the report parameters are set and the report is forced to update the data using the new report parameters. Below is a snippet of the update method called by the tick event of the timer.
/// <summary>
/// Updates the report.
/// </summary>
public void UpdateReport()
{
    AcceptanceProtocol.AcceptanceProtocol report = this.ReportViewer1.Report as AcceptanceProtocol.AcceptanceProtocol;
    report.SetFilters(companyId, userId, deviceId, cultureName);
    this.ReportViewer1.Visible = true;
    this.ReportViewer1.RefreshReport();
}

In the NeedDataSource event of the report we are fetching our data using a custom business logic object (see below):
/// <summary>
/// Handles the NeedDataSource event of the AcceptanceProtocol control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
private void AcceptanceProtocol_NeedDataSource(object sender, EventArgs e)
{
    Telerik.Reporting.Processing.Report rep = (Telerik.Reporting.Processing.Report)sender;
    this.DataSource = this.BusinessLogic.GetAcceptanceProtocol(
        this.CompanyId, this.UserId, this.DeviceId, this.CultureName,
        this.EventTypeIdFilter, this.EventTypeGroupIdFilter);
    rep.DataSource = this.DataSource;
}

The problem is that sometimes the report is showing data and sometimes not.
If we force a second GET request to the page that renders the report everything is working fine.
Some idea what is causing this?
Steve
Telerik team
 answered on 14 Jul 2010
Top users last month
Cynthia
Top achievements
Rank 1
Iron
Toby
Top achievements
Rank 3
Iron
Iron
Iron
Danielle
Top achievements
Rank 1
Iron
Iron
Joel
Top achievements
Rank 3
Bronze
Bronze
Iron
yw
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?