Telerik Forums
Reporting Forum
2 answers
114 views
Hello, everybody!

Can anyone help me make the dropdown in report parameters show an empty text.
It always automatically writes "(empty)" instead of an empty text (I only want an empty line without any words).
I will really appreciate if anyone can help.
Maks
Top achievements
Rank 1
 answered on 18 Dec 2012
2 answers
102 views
I have created several reports.
But all of them have the same parameters.
Can I have a single common parameter area for all of them and change reportsource of a reportview on the fly?
Maks
Top achievements
Rank 1
 answered on 18 Dec 2012
16 answers
560 views
I'm just trying to upgrade/update  the Telerik reporting and silverlight controls from Q3 2011 to Q1 2012.
We are still using Silverlight 4.
Is this possible?
It seems that an update is not possible without also upgrading to SL5?
Is this correct?
Regards
Dirk
Steve
Telerik team
 answered on 17 Dec 2012
4 answers
248 views
Hi,

I set up a Telerik Reporting WCF Service, a silverlight client to show the report, created a report, succesfully added the WCF report service reference to the client, and verified that it is called. Everything works up to that part.

But how do I implement the methods of the IReportService interface? I can't find examples of what I'm supposed to do. Below is the code that I guessed so far from trial and error, but this gives a xaml error.

Is there an example of how to implement a WCF reporting service?
 
In specific the method: GetPage, what is the byte[]?The manual says "Gets or sets the Byte array that contains the current report page.", but is that in pdf format?

Regards,

Bayram

    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the class name "ReportService" in code, svc and config file together.
    [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]
    public class ReportService : IReportService
    {
        public void DoWork()
        {
        }
 
        private byte[] RenderToArray(string instanceID)
        {
            Telerik.Reporting.Processing.ReportProcessor reportProcessor =
                new Telerik.Reporting.Processing.ReportProcessor();
 
            //set any deviceInfo settings if necessary
            System.Collections.Hashtable deviceInfo =
                new System.Collections.Hashtable();
 
            Telerik.Reporting.InstanceReportSource instanceReportSource =
                new Telerik.Reporting.InstanceReportSource();
 
            instanceReportSource.ReportDocument = new PowerBrowser.Web.Modules.Reporting.ReportZakenDashboard();
 
            Telerik.Reporting.Processing.RenderingResult renderingResult =
                reportProcessor.RenderReport("PDF", instanceReportSource, deviceInfo);
 
            string fileName = renderingResult.DocumentName + "." + renderingResult.Extension;
            string path = System.IO.Path.GetTempPath();
            string filePath = System.IO.Path.Combine(path, fileName);
 
            byte[] result = new byte[renderingResult.DocumentBytes.Length];
            using (System.IO.MemoryStream fs = new System.IO.MemoryStream(result))
            {
                fs.Write(renderingResult.DocumentBytes, 0, renderingResult.DocumentBytes.Length);
            }
            return result;
        }
 
        public Telerik.Reporting.Service.PageInfo GetPage(string instanceID, int pageNumber)
        {
            PageInfo info = new PageInfo()
            {
                Buffer = RenderToArray(""),
                PageNumber = 1
            };
            return info;
        }
 
        public List<Parameter> GetReportParameters(string report, NameValueDictionary deviceInfo, NameValueDictionary parameters)
        {
            List<Parameter> reportParameters = new List<Parameter>();
            return reportParameters;
        }
 
        public IList<ReportInfo> ListAvailableReports()
        {
            ReportInfo info = new ReportInfo()
            {
                Description = "Mijn zaken",
                FullName = "Rapport - Mijn zaken",
                Name = "ReportZakenDashboard"
            };
            List<ReportInfo> reports = new List<ReportInfo>();
            reports.Add(info);
            return reports;
        }
 
        public IList<ExtensionInfo> ListRenderingExtensions()
        {
            List<ExtensionInfo> extensions = new List<ExtensionInfo>();
            ExtensionInfo info = new ExtensionInfo() { LocalizedName = "PDF", Name = "PDF" };
            extensions.Add(info);
            return extensions;
        }
 
        public RenderingResult Render(string format, string report, NameValueDictionary deviceInfo, NameValueDictionary parameters)
        {
            RenderingResult renderingResult = null;
            if (report == "ReportZakenDashboard")
            {
                renderingResult = new RenderingResult()
                {
                    DocumentBytes = new byte[] { },
                    DocumentName = "Test",
                    Extension = "PDF",
                };
            }
            return renderingResult;
        }
 
        public RenderingSessionInfo RenderAndCache(string format, string report, NameValueDictionary deviceInfo, NameValueDictionary parameters)
        {
            RenderingSessionInfo info = new RenderingSessionInfo()
            {
                PageCount = 1,
                DocumentName = "Mijn zaken",
                PageNumber = 1,
                Report = "ReportZakenDashboard"
            };
            return info;
        }
    }
Peter
Telerik team
 answered on 17 Dec 2012
1 answer
374 views
I tried to add an expression =PageNumber in the Report header, and it didn't show up.   

Shouldn't PageNumber be available in all sections?

I am using the reportheader to display [=Page #: 1] text instead of ="Page #: " + PageNumber.  Then with the reportheader hidden on other pages, I am using the pageheader to show the pagenumber text for each page with a smaller footprint.

Peter
Stef
Telerik team
 answered on 17 Dec 2012
0 answers
113 views
Hello,

I need to do pie chart to show life cycle of different Pallets.

In database have values like below:

Pallet Lifecycle UsedLifecycle RemainingLifecycle
P100 100 90 10
P101 200 100 100

Am able to display Pie chart individually for P100 Or P101.
But how to show 2 charts for P100 and P101 in single report?

I used Datagroupcolumn as PalletId; but the series shown in single chart itself, ie;P100 and P101 in same chart.
How to show it in different charts?

Its urgent.

Jayanthi
jayanthi
Top achievements
Rank 1
 asked on 17 Dec 2012
0 answers
101 views
I have a report that has a few toggle visibilty sections in it and in most cases the toggle button does not print or show in the preview, but for some reason the is one section that shows and prints the toggle button.  Is there a setting somewhere that needs to be set so that it does not print?
Eric Klein
Top achievements
Rank 1
 asked on 14 Dec 2012
11 answers
570 views
Hi,
We are using Telerik Reporting Q3 2007. 
 
- How can i load a saved report dynamically at run time?
- Is there any progress about save a report definition in outer storage (like xml-file) 
- When will your Report object (Telerik.Reporting.Report)  be supporting serializing / deserializing with soap or binary formatter or other way to serialize.
Steve
Telerik team
 answered on 13 Dec 2012
2 answers
343 views
Hello,

   I have a report and viewed in silverlight, my problem is how can I change the margin at runtime? Because the user has the option to change the margin anytime.

  Thank you.
YARARMAN
Top achievements
Rank 1
 answered on 13 Dec 2012
1 answer
367 views
I have a Table used to display an Address.  Not every user fills in every field and at diplay time i'd like to just remove the Rows that have no data.

I did this so far

var recipientContact = from ro in recipientOrg.AsEnumerable()
                        join rc in _db.RecipientContacts
                       on ro.RecipientOrganizationID equals rc.RecipientOrganizationID
                        select new
                          {
                              OrgName = rc.RecipientOrganization.Name,
                               ContactName = rc.FirstName + " " + rc.Surname,
                               Address1 = rc.Address1,
                               Address2 = rc.Address2,
                               City = rc.City.CityName,
                               Province = rc.Province.NameEnglish,
                               Country = rc.Country.CountryName,
                               PostalCode = rc.PostalCode,
                               Fax = ro.FaxNumber,
                               Phone = ro.PhoneNumber
                        };
                table5.DataSource = recipientContact.ToList();
 
        private void table5_ItemDataBound(object sender, EventArgs eventArgs)
        {
 
 
 
        }

This works fine, what I was thinking was that I could, in the databound event, loop through the Rows and see which, if any had no contents and jest Delete It?

Not sure where to start there though.
Steve
Telerik team
 answered on 13 Dec 2012
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
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?