Click here to Skip to main content
15,916,188 members
Home / Discussions / WPF
   

WPF

 
AnswerRe: How to bind TreeView with nested object without using HierarchicalDatatemplate Pin
User 27100918-Oct-08 20:11
User 27100918-Oct-08 20:11 
GeneralRe: How to bind TreeView with nested object without using HierarchicalDatatemplate Pin
Michael Sync18-Oct-08 21:37
Michael Sync18-Oct-08 21:37 
GeneralRe: How to bind TreeView with nested object without using HierarchicalDatatemplate Pin
User 27100919-Oct-08 4:55
User 27100919-Oct-08 4:55 
QuestionQuick Question Pin
MrMcIntyre18-Oct-08 1:52
MrMcIntyre18-Oct-08 1:52 
AnswerRe: Quick Question Pin
User 27100918-Oct-08 20:12
User 27100918-Oct-08 20:12 
Questionhelp in xps? Pin
Dotnetkanna17-Oct-08 18:45
Dotnetkanna17-Oct-08 18:45 
AnswerRe: help in xps? Pin
touseef17-Oct-08 20:25
touseef17-Oct-08 20:25 
QuestionOdd WPF Problem Pin
Jammer17-Oct-08 12:57
Jammer17-Oct-08 12:57 
Hi All,

I'm having some trouble using some XAML and an attached property to vary a graphic in the UI. It seems to be intermittently working!! I was testing a Debug and Release version and all was working well but I've just fired it up again and its whacko!!

The XAML is:

<DataTrigger Binding="{Binding Path=(local:TreeViewItemProps.IsRootLevel), 
             RelativeSource={RelativeSource AncestorType={x:Type TreeViewItem}, Mode=FindAncestor}}" Value="True">
    <Setter TargetName="img" Property="Source" Value="/SampleSort.Modules.Browser;component/Graphics/diskdrive.png" />
</DataTrigger>
<DataTrigger Binding="{Binding Path=(local:TreeViewItemProps.IsRootLevel), 
             RelativeSource={RelativeSource AncestorType={x:Type TreeViewItem}, Mode=FindAncestor}}" Value="False">
    <Setter TargetName="img" Property="Source" Value="/SampleSort.Modules.Browser;component/Graphics/folder.png" />
</DataTrigger>


The error I get is:

Cannot convert string '/SampleSort.Modules.Browser;component/Graphics/diskdrive.png' in attribute 'Source' to object of type 'System.Windows.Media.ImageSource'. Cannot locate resource 'graphics/diskdrive.png'.


I don't get why its randomly stopped working. I haven't touch *any* code since working on this app yesterday!


AnswerRe: Odd WPF Problem Pin
User 27100918-Oct-08 20:16
User 27100918-Oct-08 20:16 
GeneralRe: Odd WPF Problem Pin
Jammer19-Oct-08 3:25
Jammer19-Oct-08 3:25 
QuestionWPF ListBoxItem Question Pin
Pedram Behroozi17-Oct-08 10:58
Pedram Behroozi17-Oct-08 10:58 
AnswerRe: WPF ListBoxItem Question Pin
User 27100918-Oct-08 20:19
User 27100918-Oct-08 20:19 
GeneralRe: WPF ListBoxItem Question Pin
Pedram Behroozi19-Oct-08 0:30
Pedram Behroozi19-Oct-08 0:30 
Questionevent notification Pin
vinod.sankuthodi16-Oct-08 23:46
vinod.sankuthodi16-Oct-08 23:46 
AnswerRe: event notification Pin
User 27100918-Oct-08 20:22
User 27100918-Oct-08 20:22 
QuestionUsing Multiple User Controls Pin
jayvee102216-Oct-08 16:14
jayvee102216-Oct-08 16:14 
AnswerRe: Using Multiple User Controls Pin
Pete O'Hanlon16-Oct-08 23:07
mvePete O'Hanlon16-Oct-08 23:07 
GeneralRe: Using Multiple User Controls Pin
Jammer16-Oct-08 23:20
Jammer16-Oct-08 23:20 
GeneralRe: Using Multiple User Controls Pin
Pete O'Hanlon16-Oct-08 23:46
mvePete O'Hanlon16-Oct-08 23:46 
GeneralRe: Using Multiple User Controls Pin
Jammer17-Oct-08 0:43
Jammer17-Oct-08 0:43 
GeneralRe: Using Multiple User Controls Pin
Pete O'Hanlon17-Oct-08 1:09
mvePete O'Hanlon17-Oct-08 1:09 
GeneralRe: Using Multiple User Controls Pin
Jammer17-Oct-08 1:41
Jammer17-Oct-08 1:41 
AnswerRe: Using Multiple User Controls Pin
Jammer16-Oct-08 23:19
Jammer16-Oct-08 23:19 
AnswerRe: Using Multiple User Controls Pin
jayvee102217-Oct-08 8:05
jayvee102217-Oct-08 8:05 
NewsQuicker way to make Silverlight animations! Pin
OTUTO15-Oct-08 21:28
OTUTO15-Oct-08 21:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.