How do I integrate User Control? #1562
-
Please show the full program code from this example: |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
Hello, the full code is in this repository: https://github.com/beto-rodriguez/LiveCharts2/tree/master/samples In your case you need the WPF sample. In the WPF sample you can find the main window, the important part is that the But that should be irrelevant, you should be able to place the chart directly inside your window without any UserControl instance, a UserControl is not required to render a chart, just ignore that UserControl, it should work the same if you place the chart inside your MainWindow class. If you want to learn more, you could clone this repo, and focus only in the WPF sample, try to run it and see how it works. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
Hello, the full code is in this repository:
https://github.com/beto-rodriguez/LiveCharts2/tree/master/samples
In your case you need the WPF sample.
In the WPF sample you can find the main window, the important part is that the
<ContentControl></ContentControl>
tag is where the user control is displayed in the app.But that should be irrelevant, you should be able to place the chart directly inside your window without any UserControl instance, a UserControl is not required to render a chart, just ignore that UserControl, it should work the same if you place the chart inside your MainWindow class.
If you want to learn more, you could clone this repo, and focus only in the WPF sample, try to…