TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
aadi kumary
NA
25
19.1k
How to display AlternationIndex in ListBox
May 31 2014 6:43 AM
Hi,
i want to display AlternationIndex in listbox , but in my code it's displaying only 0 always...
below is my code .. plz help me to display AlternationIndex.
<ListBox x:Name="listBox" AlternationCount="3">
<ListBox.ItemTemplate >
<DataTemplate >
<Canvas Margin="0,20,0,0">
<StackPanel Orientation="Vertical">
<TextBlock VerticalAlignment="Top" Text="{Binding Name }" FontSize="16" FontWeight="Bold" Margin="30,20,0,0" Foreground="Black" />
<TextBlock Text="{Binding RelativeSource={RelativeSource Mode=TemplatedParent},
Path=(ItemsControl.AlternationIndex)}" />
</StackPanel>
</Canvas>
</DataTemplate>
</ListBox.ItemTemplate>
</ListBox>
nazeerpc
Reply
Answers (
1
)
Displaying Image alternative in listbox (wpf application )
source codes for matching memory game using xaml and c#