person

person

  • NA
  • 96
  • 0

Binding WPF

Sep 3 2009 4:56 AM
Hi,

What way would the binding be set out if you want to bind an ObservableCollection<object> to specific grid rows.

Currently i have:

<ListView x:Name="DriverListBox" Grid.Column="0">
                    <ListView.ItemTemplate>
                        <DataTemplate DataType="Employee">
                            <Border BorderBrush="Black" BorderThickness="1,1,1,1">
                                <Canvas Width="110" Height="1000">
                                    <TextBlock Width="108" Text="{Binding Path=Name}">
                                    </TextBlock>
                                </Canvas>
                            </Border>
                        </DataTemplate>
                    </ListView.ItemTemplate>
                </ListView>

Ignoring the rows completely, using the listview to stack the items one below the other.
So the collection i have, item 1 should be in column 0 and row 1, item 2 in row 2, item 3 in row 3.....etc.

Thanks in advance.

Urema.

Answers (1)