WPF User Control - Round corners programmatically

Posted by morsanu on Stack Overflow See other posts from Stack Overflow or by morsanu
Published on 2010-04-08T16:18:40Z Indexed on 2010/04/08 16:33 UTC
Read the original article Hit count: 448

Filed under:
|
|

Another WPF question...

<UserControl x:Class="TKEApp.Components.UserControls.ButtonControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
    <Grid Background="Black">
        <TextBlock Foreground="White" Background="Brown" Name="lblCaption" TextAlignment="Center"></TextBlock>
    </Grid>
</UserControl>

Somwhere in the application code I have an instance of this control and I need to make it's corners rounded programmatically. Is this possible?

© Stack Overflow or respective owner

Related posts about wpf

Related posts about usercontrol