0

I have 'ProductType' column filtered, but it still is in data grid. If I apply ScaffoldColumn(false) filtering feature will disappear...

How to hide column and keep filtering option?

Thanks.

Budda
  • 18,015
  • 33
  • 124
  • 206

1 Answers1

1

I think you may need something like this :

[Display(Name = "Product Type", AutoGenerateFilter = true, AutoGenerateField = false)]
public object ProductType { get; set; }

Or, you'll need to extend the Metadata for that column. Steve Naughton shows how here.

Ash Machine
  • 9,601
  • 11
  • 45
  • 52