This is a migrated thread and some comments may be shown as answers.

WPF Report Viewer Styling

11 Answers 148 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Mike
Top achievements
Rank 1
Mike asked on 18 Nov 2012, 06:10 PM
Good Afternoon,

I am using implicit styling (not using style manager) in my current project and can't seem to be able to style the WPF report viewer with the Windows8 theme. I tried to add the resource dictionaries from the Themes.Implict Windows8 folder (ReportViewer.xaml, ReportViewerDialogBox.xaml, ReportViewerErrorStatus.xaml) without success. The resource dictionaries refer to the Silverlight report viewer and there are other references missing.

Could you please let me know how to achieve Windows8 styling for the WPF report viewer using implicit styles?

Thanks,

Mike

11 Answers, 1 is accepted

Sort by
0
Mike
Top achievements
Rank 1
answered on 18 Nov 2012, 06:21 PM
Just to add:

The parts I am missing are the export drop down button, the zoom combobox control and the animation when the report is loaded. Please see attached screenshot for details.

Thanks,

Mike
0
IvanY
Telerik team
answered on 19 Nov 2012, 05:02 PM
Hi Michael,

We would advise you to use the well known path for styling the WPF Report Viewer, since with implicit styles you may affect the reports too. Please check Creating Style in Expression Blend in order to see how to style the Report Viewer more appropriately.

If you insist on using the implicit styling the export button is of type RadComboBox and so is the zoom drop down. The loading animation is a RadProgressBar within a DialogBox. However please note that such styling is not supported by Telerik Reporting and in case of problems we might not be able to advise you accordingly.

I hope that helps.

Kind regards,
IvanY
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Mike
Top achievements
Rank 1
answered on 19 Nov 2012, 11:46 PM
Thanks for the feedback. The problem is that my whole application is based on implicit styles and this would be very hard to change. I wouldn't mind using the style manager to style the report viewer control however because the needed resources for the Wpf report viewer:
  • Telerik.Windows.Controls.dll
  • Telerik.Windows.Controls.Input.dll
  • Telerik.Windows.Controls.Navigation.dll

are added from the Binaries.NoXaml folder they do not contain the necessary information. I also can't add the normal binaries on top as they would clash with the NoXaml binaries. Is there a recommended way?

For now I have done the following:

Extract the report viewer style via Blend, then add 'BasedOn' entries for all required styles (i.e. combobox, progressbar, radtreeview and radtreeviewitem). I've also stripped out all references to the style manager.

This does work and display the buttons correctly however is there a better way?

Thanks,

Mike

0
IvanY
Telerik team
answered on 20 Nov 2012, 06:19 PM
Hi Michael,

Please check this help article since one additional reference is needed - Telerik.Windows.Data.dll. The recommended way is to use all four assemblies that get distributed with Telerik Reporting (or if you have installed the WPF controls to use the assemblies installed in the GAC).

If you are still experiencing difficulties please note that you can always send us a runnable sample that exhibits the issue so that we are able to reproduce it locally and advise you.

Regards,
IvanY
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Mike
Top achievements
Rank 1
answered on 20 Nov 2012, 10:37 PM

Hello Ivan,

Sorry maybe I am not particularly clear. Could you please have a look at the following help topic: 
WPF Help Implicit Styling

This is how I have styled my Telerik Rad Controls. As you see from the help the added references are different in that they do not contain any styling xaml because the styling is provided by implicit styles from the applications resource dictionaries. Basically what I would need is a report viewer style that doesn't override implicit styles within the used controls (combobox, slider, etc...) or if a style is used to use BasedOn to include the implicit styles (otherwise the controls don't show up as they don't have any style).

From the responses so far I take it that this approach of application styling is not compatible with Telerik Reporting at this time? If so will this be supported in the future? It would also be worth adding a note in the help file to make developers aware that this is the case.

Thanks,

Mike

0
Mike
Top achievements
Rank 1
answered on 21 Nov 2012, 07:59 AM
Please find attached a small project which demonstrates the setup.

Thanks,

Mike
0
IvanY
Telerik team
answered on 21 Nov 2012, 05:38 PM
Hello Michael,

Thank you for the provided sample. We will investigate it further and you can rest assured that we will continue working towards the integration of the two products.

For the time being you will have to use the well known way of styling our ReportViewer using Expression Blend as described in the help article mentioned in the previous post. We apologize for the temporary inconvenience. Your Telerik points have been updated.

Regards,
IvanY
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Mike
Top achievements
Rank 1
answered on 21 Nov 2012, 07:10 PM
Thanks for the information. I managed to get it to work just now. As suggested I took the style from Blend however it still needed some modifications to make it work (removing of style manager references and changing control styles to include 'BasedOn' entries to point to implicit styles).

Not sure if it's any help to someone else but I have attached the end result which works fine.

Thanks,

Mike
0
Mike
Top achievements
Rank 1
answered on 21 Nov 2012, 07:12 PM
Now attached (has to be zipped).

Mike
0
Steve
Telerik team
answered on 22 Nov 2012, 04:58 PM
Hi Mike,

We're glad you were able to make things work the way you wanted. Currently it is visible and helpful only to Telerik members as this is a private support thread, if you would like you can open a forum thread with your findings or we can convert this thread to a forum thread.

Greetings,
Steve
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Mike
Top achievements
Rank 1
answered on 11 Dec 2012, 10:20 AM
Hello Steve,

Sorry for the late reply, I would be more than happy for you too make this a forum post.

Kind Regards,

Mike
Tags
General Discussions
Asked by
Mike
Top achievements
Rank 1
Answers by
Mike
Top achievements
Rank 1
IvanY
Telerik team
Steve
Telerik team
Share this question
or