Moonlight vs. silverlight :: datagrid incompatibility?

I am trying to develop an application in the moonlight. Now I'm trying to use a DataGrid to display some data.

In an old silverlight project, I used DataGrid as follows:

<UserControl x:Class="One.Page"
    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"
    mc:Ignorable="d"
    d:DesignHeight="300" d:DesignWidth="400"
    xmlns:my="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data">
    <Grid x:Name="LayoutRoot" Background="White">
        <StackPanel Orientation="Vertical">
            <TextBlock x:Name="lbl1">lblInfo1</TextBlock>
            <TextBlock x:Name="lbl2">lblInfo2</TextBlock>
            <TextBox x:Name="txt1">Write here</TextBox>
            <Button x:Name="btn1" Content="Send" Click="btn1_Click" />
            <my:DataGrid x:Name="grData"
                        Grid.Row="1"
                        Width="500" Height="250"
                        Margin="10"
                        AutoGenerateColumns="False">

                    <my:DataGrid.Columns>
                        <my:DataGridTextColumn Header="Código" />
                        <my:DataGridTextColumn Header="Lote" />
                        <my:DataGridTextColumn Header="Ciudad" />
                        <my:DataGridTextColumn Header="País" />
                    </my:DataGrid.Columns>

            </my:DataGrid>
        </StackPanel>
    </Grid>
</UserControl>

but if I use the same code in my new moonlight project, I get a blank page. I searched for a few examples and I found a simple one:

In this example, the author uses DartaGrid just like me. Can someone explain to me why in VS2010 I can use this code, but in monodevelop 2.4 or monodevelop 2.8 I can not?

+5

All Articles