Question

I installed VS2012 and wanted to create a Silverlight application using dockpanels. I have read "somewhere" that the dockpanel component must be separately installed but I cannot find the instructions anymore using Google. MAybe someone from stackexchange community can help and point me to the place where I can find how to add the dockpanel componenet to VS2012. Many thanks

Was it helpful?

Solution 2

In the meantime I found the answer inspired by this link http://procbits.com/2011/07/19/missing-dockpanel-add-dockpanel-for-silverlight-4-or-silverlight-5 . You have to install the Silverlight Toolkit 5 which can be downloaded from here: http://silverlight.codeplex.com/releases/view/78435

OTHER TIPS

Download the Silverlight 4 Toolkit. Install it. (Yes, this will work with Silverlight 5 beta)

Add a reference to "System.Windows.Controls.Toolkit". In Silverlight 5, you will need to navigate to the file: %ProgramFiles%\Microsoft SDKs\Silverlight\v4.0\Toolkit\Apr10\Bin\System.Windows.Controls.Toolkit.dll

Add the following attribute to your UserControl: xmlns:tk="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit"

<UserControl x:Class="Project1.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:tk="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit"
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="400">

    <Grid x:Name="LayoutRoot" Background="White">
        <tk:DockPanel>

        </tk:DockPanel>
    </Grid>

</UserControl>

Source:missing-dockpanel-add-dockpanel-for-silverlight-4-or-silverlight-5

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top