Click here to Skip to main content
11,712,820 members (78,982 online)

Silverlight / WPF

 
GeneralRe: InvalidateMeasure doesn't trigger MeasureOverride call? Pin
SledgeHammer0122-Aug-12 13:40
memberSledgeHammer0122-Aug-12 13:40 
GeneralRe: InvalidateMeasure doesn't trigger MeasureOverride call? Pin
Pete O'Hanlon22-Aug-12 23:53
protectorPete O'Hanlon22-Aug-12 23:53 
GeneralRe: InvalidateMeasure doesn't trigger MeasureOverride call? Pin
SledgeHammer0123-Aug-12 5:08
memberSledgeHammer0123-Aug-12 5:08 
GeneralRe: InvalidateMeasure doesn't trigger MeasureOverride call? Pin
Pete O'Hanlon23-Aug-12 5:15
protectorPete O'Hanlon23-Aug-12 5:15 
GeneralRe: InvalidateMeasure doesn't trigger MeasureOverride call? Pin
SledgeHammer0123-Aug-12 8:34
memberSledgeHammer0123-Aug-12 8:34 
GeneralRe: InvalidateMeasure doesn't trigger MeasureOverride call? Pin
SledgeHammer0123-Aug-12 13:03
memberSledgeHammer0123-Aug-12 13:03 
QuestionWPF Problem With WrapPanel In ListBox.ItemsPanel [UPDATED] Pin
Kevin Marois20-Aug-12 14:33
memberKevin Marois20-Aug-12 14:33 
QuestionSwitch WPF UI at runtime Pin
Ed Hill _5_17-Aug-12 0:43
memberEd Hill _5_17-Aug-12 0:43 
AnswerRe: Switch WPF UI at runtime Pin
Kenneth Haugland18-Aug-12 12:54
memberKenneth Haugland18-Aug-12 12:54 
GeneralRe: Switch WPF UI at runtime Pin
Ed Hill _5_18-Aug-12 23:45
memberEd Hill _5_18-Aug-12 23:45 
AnswerRe: Switch WPF UI at runtime Pin
Abhinav S18-Aug-12 18:31
mvpAbhinav S18-Aug-12 18:31 
GeneralRe: Switch WPF UI at runtime Pin
Ed Hill _5_19-Aug-12 21:57
memberEd Hill _5_19-Aug-12 21:57 
AnswerRe: Switch WPF UI at runtime Pin
Pete O'Hanlon20-Aug-12 0:48
protectorPete O'Hanlon20-Aug-12 0:48 
QuestionWPF ListBox Question Pin
Kevin Marois15-Aug-12 15:22
memberKevin Marois15-Aug-12 15:22 
I'm working on a contacts list[^]

I have 2 questions:

1) I would like to only see the drop shadow when the contact is selected. Of course only one can be selected at any time.

2) How do i get the contact cards to flow across, right to left, then top to bottom? I'm guessing I need to implement a wrap panel, but I'm not sure how to fit it into my item template.

Here's my XAML:

<ListBox x:Name="Contacts"           
            ScrollViewer.VerticalScrollBarVisibility="Auto"
            ItemsSource="{Binding Contacts}"
            SelectedItem="{Binding SelectedContact}">
    <ListBox.ItemTemplate>
        <DataTemplate>
            <Border CornerRadius="3"
                    Height="200"
                    Width="300"
                    Padding="5"
                    Margin="8"
                    Background="White"
                    BorderBrush="DarkGray"
                    BorderThickness="1">
                <Border.Effect>
                    <DropShadowEffect Color="DarkGray"
                            ShadowDepth="7"/>
                </Border.Effect>
                <Border Margin="2"
                        CornerRadius="3"
                        Padding="4"
                        BorderBrush="LightSteelBlue"
                        BorderThickness="1">
                    <Grid>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="*"/>
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="Auto"/>
                            <ColumnDefinition Width="Auto"/>
                        </Grid.ColumnDefinitions>
                        <Image Height="45"
                                Width="45" Source="/Falcon.UI.WPF;component/Media/Images/customer_48.png"
                                Grid.Row="0"
                                Grid.Column="0"/>
                        <StackPanel Orientation="Horizontal"
                                    Grid.Row="0"
                                    Grid.Column="1">
                                    
                            <TextBlock Style="{Binding PageHeaderLabelStyle}"
                                        FontSize="28"
                                        Foreground="#2B579A"
                                        Text="{Binding FirstName}"/>
                            <TextBlock Style="{Binding PageHeaderLabelStyle}"
                                        FontSize="28"
                                        Foreground="#2B579A"
                                        Margin="5,0,0,0"
                                        Text="{Binding LastName}"/>
                        </StackPanel>
                        <TextBlock Grid.Row="1"
                                    Grid.Column="1"
                                    Style="{Binding PageHeaderLabelStyle}"
                                    FontSize="18"
                                    Foreground="#2B579A"
                                    Margin="0,-10,0,0"
                                    Text="{Binding Title}"/>
                                
                    </Grid>
                </Border>
            </Border>
 
        </DataTemplate>
    </ListBox.ItemTemplate>
            
</ListBox>

Thanks
If it's not broken, fix it until it is

AnswerRe: WPF ListBox Question Pin
Ed Hill _5_15-Aug-12 22:07
memberEd Hill _5_15-Aug-12 22:07 
GeneralRe: WPF ListBox Question Pin
Kevin Marois16-Aug-12 6:10
memberKevin Marois16-Aug-12 6:10 
QuestionComboBox Dropdown Problem Pin
John Simmons / outlaw programmer15-Aug-12 4:49
mvpJohn Simmons / outlaw programmer15-Aug-12 4:49 
AnswerRe: ComboBox Dropdown Problem Pin
Pete O'Hanlon15-Aug-12 5:12
protectorPete O'Hanlon15-Aug-12 5:12 
GeneralRe: ComboBox Dropdown Problem Pin
John Simmons / outlaw programmer15-Aug-12 5:13
mvpJohn Simmons / outlaw programmer15-Aug-12 5:13 
GeneralRe: ComboBox Dropdown Problem Pin
John Simmons / outlaw programmer15-Aug-12 5:17
mvpJohn Simmons / outlaw programmer15-Aug-12 5:17 
GeneralRe: ComboBox Dropdown Problem Pin
John Simmons / outlaw programmer15-Aug-12 6:45
mvpJohn Simmons / outlaw programmer15-Aug-12 6:45 
AnswerRe: ComboBox Dropdown Problem Pin
Pete O'Hanlon15-Aug-12 22:59
protectorPete O'Hanlon15-Aug-12 22:59 
GeneralRe: ComboBox Dropdown Problem Pin
John Simmons / outlaw programmer16-Aug-12 1:27
mvpJohn Simmons / outlaw programmer16-Aug-12 1:27 
GeneralRe: ComboBox Dropdown Problem Pin
Pete O'Hanlon16-Aug-12 1:46
protectorPete O'Hanlon16-Aug-12 1:46 
GeneralRe: ComboBox Dropdown Problem Pin
John Simmons / outlaw programmer17-Aug-12 4:05
mvpJohn Simmons / outlaw programmer17-Aug-12 4:05 
GeneralPut Blu-ray movies on New iPad and keep the file size around 2GB Pin
hihjay114-Aug-12 19:07
memberhihjay114-Aug-12 19:07 
QuestionHow to got Phone Number Pin
Vikash Yadav14-Aug-12 16:29
groupVikash Yadav14-Aug-12 16:29 
AnswerRe: How to got Phone Number Pin
Pete O'Hanlon14-Aug-12 22:20
protectorPete O'Hanlon14-Aug-12 22:20 
AnswerRe: How to got Phone Number Pin
Abhinav S14-Aug-12 23:08
mvpAbhinav S14-Aug-12 23:08 
QuestionNeed to call third party API from SL 5 Solution Pin
Tbhavesh14-Aug-12 9:03
memberTbhavesh14-Aug-12 9:03 
AnswerRe: Need to call third party API from SL 5 Solution Pin
Wes Aday14-Aug-12 9:47
memberWes Aday14-Aug-12 9:47 
AnswerRe: Need to call third party API from SL 5 Solution Pin
Anumeha Shukla16-Aug-12 2:49
memberAnumeha Shukla16-Aug-12 2:49 
QuestionCrop and save image in oval shape using silverlight Pin
Anupbala13-Aug-12 19:20
memberAnupbala13-Aug-12 19:20 
AnswerRe: Crop and save image in oval shape using silverlight Pin
Pete O'Hanlon13-Aug-12 23:04
protectorPete O'Hanlon13-Aug-12 23:04 
QuestionWPF ComboBox Binding Problem Pin
Kevin Marois12-Aug-12 10:51
memberKevin Marois12-Aug-12 10:51 
AnswerRe: WPF ComboBox Binding Problem Pin
Pete O'Hanlon12-Aug-12 11:22
protectorPete O'Hanlon12-Aug-12 11:22 
GeneralRe: WPF ComboBox Binding Problem Pin
Kevin Marois12-Aug-12 11:40
memberKevin Marois12-Aug-12 11:40 
GeneralRe: WPF ComboBox Binding Problem Pin
Pete O'Hanlon13-Aug-12 4:08
protectorPete O'Hanlon13-Aug-12 4:08 
GeneralRe: WPF ComboBox Binding Problem Pin
Kevin Marois12-Aug-12 11:47
memberKevin Marois12-Aug-12 11:47 
AnswerRe: WPF ComboBox Binding Problem Pin
Collin Jasnoch13-Aug-12 3:20
memberCollin Jasnoch13-Aug-12 3:20 
QuestionTreeView Control Item Styling Pin
Andy_L_J12-Aug-12 2:38
memberAndy_L_J12-Aug-12 2:38 
AnswerRe: TreeView Control Item Styling Pin
SledgeHammer0113-Aug-12 10:25
memberSledgeHammer0113-Aug-12 10:25 
GeneralGroupbox visibility problem in WPF after debugging and changing the combobox value Pin
karthik bandaru8-Aug-12 23:24
memberkarthik bandaru8-Aug-12 23:24 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
Ed Hill _5_9-Aug-12 0:06
memberEd Hill _5_9-Aug-12 0:06 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
karthik bandaru9-Aug-12 0:23
memberkarthik bandaru9-Aug-12 0:23 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
Ed Hill _5_9-Aug-12 0:31
memberEd Hill _5_9-Aug-12 0:31 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
karthik bandaru9-Aug-12 0:42
memberkarthik bandaru9-Aug-12 0:42 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
Ed Hill _5_9-Aug-12 0:56
memberEd Hill _5_9-Aug-12 0:56 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
Ed Hill _5_9-Aug-12 0:47
memberEd Hill _5_9-Aug-12 0:47 
GeneralRe: Groupbox visibility problem in WPF after debugging and changing the combobox value Pin
karthik bandaru9-Aug-12 0:50
memberkarthik bandaru9-Aug-12 0:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    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 | Mobile
Web03 | 2.8.150819.1 | Last Updated 27 Aug 2015
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid