suppose i have this class:
public class Foo
{
public Bar aBar {get; private set;}
public Foo(String name)
{
aBar = new Bar()
{
Name = name
}
}
}
public class Bar
{
public String Name {get; private set;}
}
How can i access the property Name from class Foo? this is what i have i XAML so far:
<Window.Resources>
<ObjectDataProvider x:Key="myFoo" ObjectType="{x:Type local:Foo}">
<ObjectDataProvider.ConstructorParameters>
<system:String>HelloWorld</system:String>
</ObjectDataProvider.ConstructorParameters>
</ObjectDataProvider>
</Window.Resources>
do i have to write a method, calling with Foo.aBar.Name, .. ??