I have static property in a class that I need to set it as ItemSource for TreeView control.
some thing like that:
<TreeView x:Name="SegTreeView" Margin="199,55,240,0" VerticalAlignment="Top" Height="88"
ItemsSource="{x:Static local:STestFrameControl._sObserverList}">
when I run my app I get this run time exception:
Cannot convert the value in attribute 'ItemsSource' to object of type 'System.Windows.Markup.StaticExtension'. Error at object 'SegmTreeView' in markup file 'DClient;component/stestframecontrol.xaml' Line 61 Position 99.
tries this solution: Binding to static property
with no help.
thanks in advance, Evyatar