Initializes a new instance of the Report class from the specified Xaml file.
Namespace: MindFusion.Reporting.Wpf
Assembly: MindFusion.Reporting.Wpf
C# Copy Code |
---|
public static Report FromStream ( |
Visual Basic Copy Code |
---|
Public Shared Function FromStream( _ |
A System.IO.Stream containing Xaml report definition.
Key value of a report in resource dictionary.
A Report instance.
The Xaml file could contain a ResourceDictionary with multiple report definitions. In that case, FromStream returns the one whose x:Key is set to the key argument value. Do not set Name properties when loading reports from an external file, or WPF's XamlLoader will throw an exception. Instead, you can set InternalName attribute if needed, which internally sets same Name value of WPF elements:
Xaml Copy Code |
---|
<ResourceDictionary> |
If you need to define just one report in the Xaml file, you can keep it as the root element. In that case, the key argument is ignored, and you can freely set Name attributes:
Xaml Copy Code |
---|
<r:Report ... ... |