Click here to Skip to main content
15,911,786 members
Home / Discussions / WPF
   

WPF

 
QuestionCollectionViewSource filteration Pin
Member 787462222-Oct-12 22:57
Member 787462222-Oct-12 22:57 
AnswerRe: CollectionViewSource filteration Pin
Mycroft Holmes23-Oct-12 0:38
professionalMycroft Holmes23-Oct-12 0:38 
QuestionTrouble decoding an image Pin
MitchG92_2422-Oct-12 22:56
MitchG92_2422-Oct-12 22:56 
AnswerRe: Trouble decoding an image Pin
Bernhard Hiller26-Oct-12 2:33
Bernhard Hiller26-Oct-12 2:33 
GeneralRe: Trouble decoding an image Pin
MitchG92_2429-Oct-12 4:11
MitchG92_2429-Oct-12 4:11 
QuestionHow does Wcf Ria Services connect Access? Pin
Apocalypse Now21-Oct-12 22:42
Apocalypse Now21-Oct-12 22:42 
QuestionMVVM & Collections of Collections Pin
cjb11021-Oct-12 22:13
cjb11021-Oct-12 22:13 
AnswerRe: MVVM & Collections of Collections Pin
SledgeHammer0122-Oct-12 9:44
SledgeHammer0122-Oct-12 9:44 
GeneralRe: MVVM & Collections of Collections Pin
cjb11022-Oct-12 22:01
cjb11022-Oct-12 22:01 
GeneralRe: MVVM & Collections of Collections Pin
SledgeHammer0123-Oct-12 6:34
SledgeHammer0123-Oct-12 6:34 
QuestionSilverlight on Linux(Ubuntu) Pin
anil03318-Oct-12 4:39
anil03318-Oct-12 4:39 
AnswerRe: Silverlight on Linux(Ubuntu) Pin
Mycroft Holmes18-Oct-12 17:18
professionalMycroft Holmes18-Oct-12 17:18 
GeneralRe: Silverlight on Linux(Ubuntu) Pin
ThatsAlok19-Oct-12 2:07
ThatsAlok19-Oct-12 2:07 
GeneralRe: Silverlight on Linux(Ubuntu) Pin
Mycroft Holmes19-Oct-12 13:31
professionalMycroft Holmes19-Oct-12 13:31 
AnswerRe: Silverlight on Linux(Ubuntu) Pin
ThatsAlok21-Oct-12 1:52
ThatsAlok21-Oct-12 1:52 
GeneralRe: Silverlight on Linux(Ubuntu) Pin
trønderen12-Dec-12 11:50
trønderen12-Dec-12 11:50 
GeneralRe: Silverlight on Linux(Ubuntu) Pin
Mycroft Holmes12-Dec-12 13:19
professionalMycroft Holmes12-Dec-12 13:19 
QuestionForm_Load equivalent from C#.Silverlight Pin
wizshrutz15-Oct-12 17:54
wizshrutz15-Oct-12 17:54 
AnswerRe: Form_Load equivalent from C#.Silverlight Pin
Abhinav S15-Oct-12 18:09
Abhinav S15-Oct-12 18:09 
AnswerRe: Form_Load equivalent from C#.Silverlight Pin
dbaseman23-Oct-12 17:01
dbaseman23-Oct-12 17:01 
QuestionWPF PropertyGrid with Custom Editor Pin
#realJSOP15-Oct-12 10:17
professional#realJSOP15-Oct-12 10:17 
QuestionHow to draw a vertical line chart? Pin
haody007014-Oct-12 21:38
haody007014-Oct-12 21:38 
NewsWPF TreeView Problem Pin
Kevin Marois12-Oct-12 17:19
professionalKevin Marois12-Oct-12 17:19 
I have this data:

<?xml version="1.0" encoding="utf-8"?>
<ArrayOfFolderEntity xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <FolderEntity Id="0" FolderName="Projects" Description="">
    <Folders>
      <FolderEntity Id="3" FolderName="Folder 1" Description="Folder 1 Desc ">
        <Folders />
        <Files>
          <FileEntity Id="1" FileName="File A" Description="File A Desc " />
          <FileEntity Id="2" FileName="File B" Description="File B Desc " />
        </Files>
      </FolderEntity>
      <FolderEntity Id="6" FolderName="Folder 2" Description="Folder 2 Desc ">
        <Folders />
        <Files>
          <FileEntity Id="4" FileName="File C" Description="File C Desc " />
          <FileEntity Id="2" FileName="File B" Description="File B Desc " />
        </Files>
      </FolderEntity>
    </Folders>
    <Files />
  </FolderEntity>
</ArrayOfFolderEntity>


and after it's deserialized it populated a list if Folders and Files:

Then in the view I have TreeView:

<TreeView x:Name="tvwItems"
            BorderThickness="0"
            Background="Transparent"
            Grid.Row="1"
            Grid.Column="0"
            Margin="0,2,0,2"
            ItemsSource="{Binding Folders}">
            
    <TreeView.Resources>
        <HierarchicalDataTemplate DataType="{x:Type entities:FolderEntity}" 
                                    ItemsSource="{Binding Folders}">
            <TextBlock Text="{Binding Path=FolderName}" />
        </HierarchicalDataTemplate>
        <DataTemplate DataType="{x:Type entities:FileEntity}" >
            <TextBlock Text="{Binding Path=FileName}" />
        </DataTemplate>
    </TreeView.Resources>
            
</TreeView>


The data is being loaded correctly, but when It runs all I see is

Projects
  Folder 1
  Folder 2


... no files.

What am I doing wrong?
If it's not broken, fix it until it is

GeneralRe: WPF TreeView Problem Pin
Mycroft Holmes14-Oct-12 15:31
professionalMycroft Holmes14-Oct-12 15:31 
GeneralRe: WPF TreeView Problem Pin
#realJSOP15-Oct-12 11:18
professional#realJSOP15-Oct-12 11:18 

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.