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

Diagram via NuGet

2 Answers 53 Views
Diagram
This is a migrated thread and some comments may be shown as answers.
Mathias
Top achievements
Rank 1
Mathias asked on 07 Mar 2019, 01:24 PM

Hello,

I'm referencing Telerik UI for WPF assemblies via NuGet which works fine. But when I tried to use RadDiagram in a simple project the Diagram does not display at all using the references from NuGet.

If I remove the NuGet packages in the project and add all necessary references from local disk the diagramm displays as expected. If I switch back to NuGet it does not work again.

Is there something I made wrong?

 

<packages>
  <package id="Telerik.Windows.Controls.Diagrams.for.Wpf" version="2019.1.220" targetFramework="net45" />
  <package id="Telerik.Windows.Controls.for.Wpf" version="2019.1.220" targetFramework="net45" />
  <package id="Telerik.Windows.Diagrams.Core.for.Wpf" version="2019.1.220" targetFramework="net45" />
</packages>

 

<telerik:RadDiagram>
    <telerik:RadDiagramShape x:Name="Shape1"
                        Content="Shape 1"
                        Position="80,20" />
    <telerik:RadDiagramShape x:Name="Shape2"
                        Content="Shape 2"
                        Position="320,20" />
</telerik:RadDiagram>

2 Answers, 1 is accepted

Sort by
0
Martin Ivanov
Telerik team
answered on 08 Mar 2019, 06:41 AM
Hello Mathias,

The referenced packages contain the NoXaml version of UI for WPF. The diagram is not shown because the theme dll is not referenced and the required resource dictionaries are not merged. You can read more about this in the Xaml vs. NoXaml and Setting a Theme articles.

To resolve it use one of the following two approaches:
  • Reference the Xaml version of the diagram dlls. The Xaml nuget packages end with .Xaml in the end of the package name.

    Telerik.Windows.Controls.Diagrams.for.Wpf.Xaml
    Telerik.Windows.Controls.for.Wpf.Xaml
    Telerik.Windows.Diagrams.Core.for.Wpf.Xaml
  • Or you can go to the Available Themes article. Choose a theme and download its nuget package. Then merge the theme resources as explained in the Setting a Theme article. For example, the nuget with the Fluent theme dll is called "Telerik.Windows.themes.Fluent.for.Wpf".

Regards,
Martin Ivanov
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
Mathias
Top achievements
Rank 1
answered on 08 Mar 2019, 09:36 AM
great, thank you.
Tags
Diagram
Asked by
Mathias
Top achievements
Rank 1
Answers by
Martin Ivanov
Telerik team
Mathias
Top achievements
Rank 1
Share this question
or