silverlight2008. 8. 18. 20:14

레퍼런스에 system.windows.controls.data를 추가하고


page.xaml에 이것을 userControl에 추가시킨후

  xmlns:my="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data"      

    
        <my:DataGrid x:Name ="searchList">
           
           
        </my:DataGrid>
이렇게 불러오면 된다

풀소스

<UserControl x:Class="SearchBook.Page"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:my="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data"      
    Width="800" Height="500">
    <Grid x:Name="LayoutRoot" Background="White">
       
        <my:DataGrid x:Name ="searchList">
           
           
        </my:DataGrid>

    </Grid>
</UserControl>

참고

http://blogs.msdn.com/scmorris/archive/2008/03/21/using-the-silverlight-datagrid.aspx

Posted by 동동(이재동)