Click here to Skip to main content
13,141,747 members (59,183 online)

Silverlight / WPF

 
Questionbeginner : listView, add scrollBar Pin
dominioYP26-Sep-12 3:50
memberdominioYP26-Sep-12 3:50 
QuestionTrying to set focus on DataGrid with DataGridTemplateColumn Pin
abollmeyer23-Sep-12 3:44
memberabollmeyer23-Sep-12 3:44 
AnswerRe: Trying to set focus on DataGrid with DataGridTemplateColumn Pin
abollmeyer24-Sep-12 14:13
memberabollmeyer24-Sep-12 14:13 
QuestionOn ContextMenu MouseLeave Pin
Kenneth Haugland21-Sep-12 3:46
memberKenneth Haugland21-Sep-12 3:46 
AnswerRe: On ContextMenu MouseLeave Pin
Kenneth Haugland21-Sep-12 13:42
memberKenneth Haugland21-Sep-12 13:42 
QuestionWPF DataGrid Not SHowing Any Data Pin
Kevin Marois20-Sep-12 11:30
memberKevin Marois20-Sep-12 11:30 
AnswerRe: WPF DataGrid Not SHowing Any Data Pin
Kenneth Haugland20-Sep-12 11:47
memberKenneth Haugland20-Sep-12 11:47 
GeneralRe: WPF DataGrid Not SHowing Any Data Pin
Pete O'Hanlon20-Sep-12 11:59
protectorPete O'Hanlon20-Sep-12 11:59 
GeneralRe: WPF DataGrid Not SHowing Any Data Pin
Kenneth Haugland20-Sep-12 12:10
memberKenneth Haugland20-Sep-12 12:10 
AnswerRe: WPF DataGrid Not SHowing Any Data Pin
Pete O'Hanlon20-Sep-12 12:01
protectorPete O'Hanlon20-Sep-12 12:01 
GeneralRe: WPF DataGrid Not SHowing Any Data Pin
Kevin Marois20-Sep-12 13:23
memberKevin Marois20-Sep-12 13:23 
GeneralRe: WPF DataGrid Not SHowing Any Data Pin
Pete O'Hanlon20-Sep-12 13:58
protectorPete O'Hanlon20-Sep-12 13:58 
Questionstackedbarseries chart: change the axes display Pin
ashlyacht19-Sep-12 10:03
memberashlyacht19-Sep-12 10:03 
Question[XML] XML binding Pin
Jayme6519-Sep-12 7:10
memberJayme6519-Sep-12 7:10 
I have an XML file structured this way:
<Emulators>
  <Settings>
    <vol name="10"/>    
    <Volume>10</Volume>
    <Keys name="key1" value="1" />
    <Keys name="key2" value="2" />
    <Keys name="key3" value="3" />
    <Keys name="key4" value="4" />
  </Settings>
  <System>
    <Name>name1</Name>
    <Icon>name1.png</Icon>
    <topplayed>
      <Top>top1</Top>
      <Top>top2</Top>
      <Top>top3</Top>
    </topplayed>
  </System>
<System>
    <Name>name2</Name>
    <Icon>name2.png</Icon>
    <topplayed>
      <Top>top4</Top>
      <Top>top5</Top>
      <Top>top6</Top>
    </topplayed>
  </System>
</Emulators>


I get no difficulties binding to <settings> tag, as well as tags contained into it.
I get no difficulties to bind the <system> tag into a list box.....but I don't know how to bind to tags into <topplayed>.
How to populate a listbox with all <topplayed> elements of the currently selected <system>?

<Window x:Class="MainWindow"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:WpfApplication1"         
    Title="MainWindow" Height="721" Width="525" Background="#FF4E4E64">
    <Grid Name="Grid1">
        <Grid.DataContext>
            <XmlDataProvider x:Name="SystemData" Source="C:\Users\Portable\Desktop\taper\WpfApplication1\Resources\Systems2.xml" XPath="Emulators" />
        </Grid.DataContext>
        <Grid.Resources>
            <DataTemplate x:Key="Resource1">
                <Label Content="{Binding XPath=@name}"/>
            </DataTemplate>
            <DataTemplate x:Key="Resource2">
                <Label Content="{Binding XPath=@value}"/>
            </DataTemplate>
            <DataTemplate x:Key="Resource3">
                <Label Content="{Binding XPath=Name}"/>
            </DataTemplate>
            <DataTemplate x:Key="Resource4">
                <Label Content="{Binding XPath=Top}"/>
            </DataTemplate>
        </Grid.Resources>
        <TextBox Text="{Binding XPath=Settings/Volume}" Height="30" HorizontalAlignment="Left" Margin="12,12,0,0" Name="TextBox5" VerticalAlignment="Top" Width="196" />
        <ListBox ItemsSource="{Binding XPath=Settings/Keys}" ItemTemplate="{StaticResource Resource1}" IsSynchronizedWithCurrentItem="True" Height="92" HorizontalAlignment="Left" Margin="12,48,0,0" Name="ListBox1" VerticalAlignment="Top" Width="196" />
        <ListBox ItemsSource="{Binding XPath=Settings/Keys}" ItemTemplate="{StaticResource Resource2}" Height="92" HorizontalAlignment="Left" IsSynchronizedWithCurrentItem="True" Margin="214,48,0,0" Name="ListBox2" VerticalAlignment="Top" Width="196" />
        <ListBox ItemsSource="{Binding XPath=System}" ItemTemplate="{StaticResource Resource3}" IsSynchronizedWithCurrentItem="True" Height="104" HorizontalAlignment="Left" Margin="12,185,0,0" Name="ListBox3" VerticalAlignment="Top" Width="196" />
        <ListBox ItemsSource="{Binding XPath=System/topplayed}" ItemTemplate="{StaticResource Resource4}" Height="74" HorizontalAlignment="Left" Margin="12,295,0,0" Name="ListBox4" VerticalAlignment="Top" Width="196" />
    </Grid>
</Window>




Thank you very much!!
Questionplay streaming videos from internet in wpf Pin
sudeep kushwaha17-Sep-12 18:31
membersudeep kushwaha17-Sep-12 18:31 
AnswerRe: play streaming videos from internet in wpf Pin
Mycroft Holmes17-Sep-12 20:05
memberMycroft Holmes17-Sep-12 20:05 
QuestionItemsControl with Horizontal orientation Pin
Kenneth Haugland17-Sep-12 7:25
memberKenneth Haugland17-Sep-12 7:25 
AnswerRe: ItemsControl with Horizontal orientation Pin
Abhinav S17-Sep-12 7:49
mvpAbhinav S17-Sep-12 7:49 
AnswerRe: ItemsControl with Horizontal orientation Pin
Kenneth Haugland17-Sep-12 8:04
memberKenneth Haugland17-Sep-12 8:04 
GeneralRe: ItemsControl with Horizontal orientation Pin
Abhinav S17-Sep-12 17:25
mvpAbhinav S17-Sep-12 17:25 
GeneralRe: ItemsControl with Horizontal orientation Pin
Kenneth Haugland17-Sep-12 20:24
memberKenneth Haugland17-Sep-12 20:24 
AnswerRe: ItemsControl with Horizontal orientation Pin
Kenneth Haugland17-Sep-12 9:35
memberKenneth Haugland17-Sep-12 9:35 
QuestionWPF Editable ComboxBox Question Pin
Kevin Marois14-Sep-12 10:46
memberKevin Marois14-Sep-12 10:46 
AnswerRe: WPF Editable ComboxBox Question Pin
SledgeHammer0114-Sep-12 11:17
memberSledgeHammer0114-Sep-12 11:17 
GeneralRe: WPF Editable ComboxBox Question Pin
Kevin Marois15-Sep-12 17:21
memberKevin Marois15-Sep-12 17:21 
GeneralRe: WPF Editable ComboxBox Question Pin
SledgeHammer0116-Sep-12 7:18
memberSledgeHammer0116-Sep-12 7:18 
GeneralRe: WPF Editable ComboxBox Question Pin
Kevin Marois16-Sep-12 8:55
memberKevin Marois16-Sep-12 8:55 
GeneralRe: WPF Editable ComboxBox Question Pin
SledgeHammer0116-Sep-12 9:14
memberSledgeHammer0116-Sep-12 9:14 
GeneralRe: WPF Editable ComboxBox Question Pin
Kevin Marois16-Sep-12 9:31
memberKevin Marois16-Sep-12 9:31 
GeneralRe: WPF Editable ComboxBox Question Pin
SledgeHammer0116-Sep-12 10:15
memberSledgeHammer0116-Sep-12 10:15 
GeneralRe: WPF Editable ComboxBox Question Pin
Kevin Marois16-Sep-12 10:25
memberKevin Marois16-Sep-12 10:25 
QuestionWPF Datagrid linked to URL Pin
abollmeyer13-Sep-12 18:14
memberabollmeyer13-Sep-12 18:14 
AnswerRe: WPF Datagrid linked to URL Pin
Pete O'Hanlon13-Sep-12 20:52
protectorPete O'Hanlon13-Sep-12 20:52 
GeneralRe: WPF Datagrid linked to URL Pin
abollmeyer13-Sep-12 22:50
memberabollmeyer13-Sep-12 22:50 
GeneralRe: WPF Datagrid linked to URL Pin
Pete O'Hanlon13-Sep-12 23:23
protectorPete O'Hanlon13-Sep-12 23:23 
GeneralRe: WPF Datagrid linked to URL Pin
abollmeyer14-Sep-12 21:42
memberabollmeyer14-Sep-12 21:42 
QuestionUN Register Scriptable Object Pin
Marc Vandeputte13-Sep-12 7:07
memberMarc Vandeputte13-Sep-12 7:07 
AnswerRe: UN Register Scriptable Object Pin
Clifford Nelson13-Sep-12 8:34
memberClifford Nelson13-Sep-12 8:34 
GeneralRe: UN Register Scriptable Object Pin
Marc Vandeputte13-Sep-12 10:41
memberMarc Vandeputte13-Sep-12 10:41 
GeneralRe: UN Register Scriptable Object Pin
Clifford Nelson13-Sep-12 11:19
memberClifford Nelson13-Sep-12 11:19 
QuestionWCF error - CommunicationException: Error in deserializing body of reply message for operati Pin
vanikanc12-Sep-12 15:33
membervanikanc12-Sep-12 15:33 
QuestionWpf Datagrid Pin
sudeep kushwaha12-Sep-12 2:38
membersudeep kushwaha12-Sep-12 2:38 
AnswerRe: Wpf Datagrid Pin
Pete O'Hanlon12-Sep-12 3:03
protectorPete O'Hanlon12-Sep-12 3:03 
GeneralRe: Wpf Datagrid Pin
SledgeHammer0112-Sep-12 11:55
memberSledgeHammer0112-Sep-12 11:55 
AnswerRe: Wpf Datagrid Pin
Clifford Nelson12-Sep-12 12:19
memberClifford Nelson12-Sep-12 12:19 
GeneralRe: Wpf Datagrid Pin
SledgeHammer0112-Sep-12 12:27
memberSledgeHammer0112-Sep-12 12:27 
AnswerRe: Wpf Datagrid Pin
Clifford Nelson12-Sep-12 12:34
memberClifford Nelson12-Sep-12 12:34 
GeneralRe: Wpf Datagrid Pin
SledgeHammer0112-Sep-12 13:29
memberSledgeHammer0112-Sep-12 13:29 
QuestionWPF groupbox visibility by combobox value selected Pin
karthik bandaru11-Sep-12 20:33
memberkarthik bandaru11-Sep-12 20:33 
AnswerRe: WPF groupbox visibility by combobox value selected Pin
Mycroft Holmes11-Sep-12 20:54
memberMycroft Holmes11-Sep-12 20:54 

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.


Advertise | Privacy |
Web02 | 2.8.170915.1 | Last Updated 15 Sep 2017
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid