<UserControl 
  x:Class="BusinessApplication7.MainPage"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:navigation="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation" 
  xmlns:uriMapper="clr-namespace:System.Windows.Navigation;assembly=System.Windows.Controls.Navigation"
  xmlns:dataControls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Data.DataForm.Toolkit" 
  xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  xmlns:telerikInput="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Input"
  xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
  xmlns:ria="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.DomainServices"
  xmlns:gridView="clr-namespace:Telerik.Windows.Controls.GridView;assembly=Telerik.Windows.Controls.GridView"
  xmlns:local="clr-namespace:BusinessApplication7.Web"
  mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480">

    <Grid x:Name="LayoutRoot" Background="White">
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
        </Grid.RowDefinitions>
        <Grid.Resources>
            <ria:DomainDataSource x:Name="NorthwindDataSource" AutoLoad="True" QueryName="GetOrderDetails">
                <!--<ria:DomainDataSource.FilterDescriptors>
                    <ria:FilterDescriptor Operator="IsEqualTo" PropertyPath="SupplierID" Value="{Binding ElementName=radComboBox1, Path=SelectedItem.SupplierID}" />
                </ria:DomainDataSource.FilterDescriptors>-->
                <ria:DomainDataSource.DomainContext>
                    <local:DomainService1/>
                </ria:DomainDataSource.DomainContext>
                <ria:DomainDataSource.SortDescriptors>
                    <ria:SortDescriptor PropertyPath="OrderID"/>
                </ria:DomainDataSource.SortDescriptors>
            </ria:DomainDataSource>
        </Grid.Resources>

        <telerik:RadDataPager Source="{Binding Items, ElementName=radGridView}" PageSize="20" Grid.Row="0"/>
        
        <telerik:RadGridView x:Name="radGridView" Grid.Row="1" ShowInsertRow="False" Height="400"
                               Margin="0,68,0,-68" AutoGenerateColumns="True" ItemsSource="{Binding Data, ElementName=NorthwindDataSource}">
        </telerik:RadGridView>

        

    </Grid>

</UserControl>