"Object reference not set to an instance of an object" error (RibbonControlsLibrary)

Jun 3, 2009 at 1:39 PM
Edited Jun 3, 2009 at 1:44 PM

I have a simple window where I inserted Ribbon control, but the following error occurs: "Object reference not set to an instance of an object".

I checked all references for hundred times, but resultless. Help to get rid of this error!

Here's XAML:

 

[code]

<Window x:Class="Bonus"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:r="clr-namespace:Microsoft.Windows.Controls.Ribbon;assembly=RibbonControlsLibrary"
        Title="Bonus" Height="300" Width="300">

    <Grid>
        <r:Ribbon>
            <r:RibbonTab Label="Home">
                <r:RibbonGroup Name="grp">
                </r:RibbonGroup>
            </r:RibbonTab>
        </r:Ribbon>
    </Grid>

</Window>

[/code]

Jun 4, 2009 at 3:05 PM

Did you try adding a control to the RibbonGroup?

Jun 5, 2009 at 5:20 AM

Look at the XAML - there's RibbonGroup already. What do you mean exactly?