Powered by MSDN

US - English
NEW! Silverlight 5 is available Learn More

WCF RIA Services cannot find FilterDescriptor RSS

3 replies

Last post Jan 12, 2010 01:09 PM by raccoon

(0)
  • raccoon

    raccoon

    Member

    69 Points

    135 Posts

    WCF RIA Services cannot find FilterDescriptor

    Jan 11, 2010 09:06 PM | LINK

    Hi,

    does anyone ever encounter this problem before?

    Error 1 The property 'FilterDescriptors' does not exist on the type 'StackPanel' in the XML namespace 'clr-namespace:System.Windows.Controls;assembly=System.Windows.Ria.Controls'. C:\Users\Silverlight3\Desktop\REVDemocode\WCFRIAServices\HRApp\HRApp\Views\EmployeeList.xaml 35 18 HRApp

     

    my reference in XAML is:

    xmlns:riaControls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Ria.Controls"

     

    this reference works well with the SortDescriptor before....

     

    Thanks,

    raccoon

    filterdescriptor

    If you are in Singapore please join the group of
    "Silverlight Singapore" on Facebook.
  • haipt

    haipt

    Member

    62 Points

    28 Posts

    Re: WCF RIA Services cannot find FilterDescriptor

    Jan 12, 2010 03:00 AM | LINK

    i think you must try to set FilterDescriptor in code behind first !

  • raccoon

    raccoon

    Member

    69 Points

    135 Posts

    Re: Re: WCF RIA Services cannot find FilterDescriptor

    Jan 12, 2010 07:11 AM | LINK

    hi.. but I already have it under the databinding part in XAML, as attach code below, so I dont think I need the code behind. Below are some of the codes regarding filterdescriptor that I highlight, and on the lower area there is datagrid binding.. any idea why it generates the error that I mention.

     

           <StackPanel Orientation="Horizontal"                   HorizontalAlignment="Right"                   Margin="0,-16,0,0">         <TextBlock VerticalAlignment="Center"                     Text="Min Vacation Hours Filter" />         <TextBox x:Name="vacationHoursText" Width="75"                   FontSize="11" Margin="4" Text="0"/>      </StackPanel>      <riaControls:DomainDataSource             x:Name="employeeDataSource"             LoadSize="20"             QueryName="GetSalariedEmployees"             AutoLoad="True">        <riaControls:DomainDataSource.DomainContext>          <ds:OrganizationContext/>         </riaControls:DomainDataSource.DomainContext>        <riaControls:DomainDataSource.SortDescriptors>          <riaData:SortDescriptor PropertyPath="VacationHours"                                   Direction="Ascending" />        </riaControls:DomainDataSource.SortDescriptors>        <riaControls:DomainDataSource.FilterDescriptors>         <riaData:FilterDescriptorCollection>           <riaData:FilterDescriptor                  PropertyPath="VacationHours"                  Operator="IsGreaterThanOrEqualTo">             <riaControls:ControlParameter                  ControlName="vacationHoursText"                  PropertyName="Text"                  RefreshEventName="TextChanged" />           </riaData:FilterDescriptor>          </riaData:FilterDescriptorCollection>       </riaControls:DomainDataSource.FilterDescriptors>       </riaControls:DomainDataSource>       <data:DataGrid MinHeight="100"                IsReadOnly="True"                ItemsSource="{Binding Data, ElementName=employeeDataSource}"               x:Name="dataGrid1" />  </StackPanel>
    If you are in Singapore please join the group of
    "Silverlight Singapore" on Facebook.
  • raccoon

    raccoon

    Member

    69 Points

    135 Posts

    Re: Re: Re: WCF RIA Services cannot find FilterDescriptor

    Jan 12, 2010 01:09 PM | LINK

    Hi everything is ok by now. I just copy the code at the wrong area on my solutions file thanks.
    If you are in Singapore please join the group of
    "Silverlight Singapore" on Facebook.