The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

Last post 11-23-2009 4:43 AM by sjnaughton. 4 replies.

Sort Posts:

  • The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

    09-05-2008, 5:15 PM
    • Member
      629 point Member
    • levalencia
    • Member since 06-12-2006, 3:34 PM
    • Posts 281

     I tried this

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Web.DynamicData;
    using System.Xml.Linq;
    using System.Web;
    using System.Web.Security;
    using System.Data;
    using System.ComponentModel.DataAnnotations;
    using System.Web.UI;
    using System.Web.UI.WebControls;
    using System.ComponentModel;
    using Microsoft.Web.DynamicData;



    namespace Sodexo.Entities
    {
        [MetadataType(typeof(AssetMetaData))]
        public partial class Asset
        {
           
        }

        [DisplayName("Activo")]
        public class AssetMetaData
        {
            public object Id { get; set; }

           
            [DisplayName("Nombre Activo")]
            [Filter(FilterControl = "AutoComplete")]
            [Required(ErrorMessage = "Este campo es Requerido")]
            public object Name { get; set; }

            [Required(ErrorMessage = "Este campo es Requerido")]
            [DisplayName("Descripción Activo")]
           
            public object Description { get; set; }

            [Required(ErrorMessage = "Este campo es Requerido")]
            [DisplayName("Marca")]
            public object Brand { get; set; }

            [Required(ErrorMessage = "Este campo es Requerido")]
            [DisplayName("Modelo")]
            public object Model { get; set; }

            [Required(ErrorMessage = "Este campo es Requerido")]
            [DisplayName("Serial")]
            public object Serial { get; set; }


            [Required(ErrorMessage = "Este campo es Requerido")]
            [DisplayName("Ubicación")]
            public object Location { get; set; }

            [DisplayName("Sucursal")]
            public object Branch { get; set; }

            [Required(ErrorMessage = "Este campo es Requerido")]
            [DisplayName("Capacidad")]
            public object Capacity { get; set; }

            [DisplayName("Tipo de Servicio")]
            public object ServiceType { get; set; }
        }
    }

     

    But I got an error on debuggin time

     The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.InvalidOperationException: The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

    Source Error:


    Line 32:     protected void Page_Init(object sender, EventArgs e) {
    Line 33:         if (!Page.IsPostBack) {
    Line 34:             PopulateListControl(DropDownList1);
    Line 35:
    Line 36:             // Set the initial value if there is one
     

     

     Does it make sense??

    Please help!!

    Thank you veyr much!

    Don't forget to click "Mark as Answer" on the post that helped you.
    Luis Esteban Valencia - Medellin - Colombia
    http://wantmvp.blogspot.com/
    MCP, MCTS SQL 2006, MCTS WEB APP, MCTS WINFORMS, MCTS DISTRIBUTED, NEXT MCPD ENTERPRISE APPLICATION DEVELOPER
  • Re: The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

    09-06-2008, 5:15 AM
    • Star
      12,250 point Star
    • sjnaughton
    • Member since 04-29-2008, 1:11 PM
    • Newton-le-Willows, Merseyside, UK
    • Posts 2,558
    • TrustedFriends-MVPs

    I was getting this error when I was missing a referance in the Web.Config to Dynamic Data Futures please go through my article:

    Dynamic Data Futures – Part 1 Adding Advanced Filters

    I know its long winded but I did'nt want to miss any little bit out Big Smile

    Steve Big Smile

    Always seeking an elegant solution.
    [Oh! If olny I colud tpye!]
    c# Bits blog
    Oh, and don't forget to mark as answer any posts that help you Big Smile
  • Re: The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

    11-22-2009, 6:27 PM
    • Member
      8 point Member
    • steve_mew
    • Member since 04-12-2004, 3:55 PM
    • Posts 21

    I seem to be getting the same problem. I have a project with 13 tables. All pages work fine except the page associated with my Employees Table.  [Col#1 PK(int), Col#2 FirstName(varchar), Col#3 LastName (varchar)]

    Pretty sure this is not a Web.Config issue.

    On adding a filter  [LastName] I also am getting the InvalidOperationException.

    "The filter control 'LastNameFilter' does not support this operation because it is associated with an unsupported column 'LastName'."

    It makes no sense.

    I have other pages that are the same template with similar table schema and they work just fine. Any ideas ?

    ------------------------------------------------------------------------------------------------------------------------------------------



    <%@ Page Language="C#" MasterPageFile="~/Site.master" CodeBehind="ListDetails.aspx.cs" Inherits="DynamicData01.EmployeeListDetails" %>
    <%@ Register src="~/DynamicData/Content/GridViewPager.ascx" tagname="GridViewPager" tagprefix="asp" %>
    <%@ Register src="~/DynamicData/Content/FilterUserControl.ascx" tagname="DynamicFilter" tagprefix="asp" %>

    <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
        <asp:DynamicDataManager ID="DynamicDataManager1" runat="server" AutoLoadForeignKeys="true" />
        <%--<h2><%= GridDataSource.GetTable().DisplayName %></h2>--%>
        
        <h4><span>Filter View:</span></h4>
        <asp:ScriptManagerProxy runat="server" ID="ScriptManagerProxy1" />
        
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
            <ContentTemplate>
                <asp:ValidationSummary ID="ValidationSummary1" runat="server" EnableClientScript="true"
                    HeaderText="List of validation errors" />
                <asp:DynamicValidator runat="server" ID="GridViewValidator" ControlToValidate="GridView1" Display="None" />
                <table>
                    <tr>
                        <td><asp:Label ID="lblFltrLastName" runat="server">LastName:</asp:Label></td>
                        <td>
                        <%-- LastName Selector--%>            
                        <asp:DynamicFilter runat="server" ID="LastNameFilter" DataField="LastName"
                        OnSelectedIndexChanged="OnFilterSelectedIndexChanged" />  
                        </td>
                    </tr>            
                </table>

    .....

    ....

    ..

  • Re: The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

    11-22-2009, 8:40 PM
    • Member
      8 point Member
    • steve_mew
    • Member since 04-12-2004, 3:55 PM
    • Posts 21

    Hmm does it have anything to do with the fact that  Dynamic Data only supports out of the box:

    • Foreign_Key Columns 
    • Booleans

    It does not do plain old text / char / varchar columns. In other words anything that is not a foreign key or a Boolean is not supported

    So, I am going to have to dig around on this. I suspect they’ll just have to be plain old drop down lists ?

     s

  • Re: The filter control 'CategoryFilter' does not support this operation because it is associated with an unsupported column 'Name'.

    11-23-2009, 4:43 AM
    • Star
      12,250 point Star
    • sjnaughton
    • Member since 04-29-2008, 1:11 PM
    • Newton-le-Willows, Merseyside, UK
    • Posts 2,558
    • TrustedFriends-MVPs

    steve_mew:
    "The filter control 'LastNameFilter' does not support this operation because it is associated with an unsupported column 'LastName'."
     

    This error means you are trying to filter a column that is not filterable, because the filter you are telling the system to use is incorrect, so you can look at using a different filter or create a custom filter.

    Steve Big Smile

    Always seeking an elegant solution.
    [Oh! If olny I colud tpye!]
    c# Bits blog
    Oh, and don't forget to mark as answer any posts that help you Big Smile
    Filed under:
Page 1 of 1 (5 items)