That all depends on how you are determining which the most recent DVD [:D] if you are using a date field then you could look at implementing a top ten filter in dd Preview 4 or DDv2 in VS2010 Beta 2.
There is not much that will enable you to do this (if I am understanding what you want) in DDv1.
Dynamic Data
See my blog C# Bits | Twitter @sjnaughton Always seeking an elegant solution.
Wow! That looks awesome. But I have one question for now. I have my site on a local server here, and im creating this site on my desktop computer. After I have published the project, do the
<div>Dynamic Data Filtering 1.10 have to be installed on the server to make this work?</div><div>
</div><div>Thanks </div>
Just tried it and it works
But I got a question. Do I have to make a partial classfile for all tables I have now, or is it possible to just enable this to one or two tables if I Create custom sites?
no you can create them pice meal just add each class as you need it [:D] so it you only need to add filters to one talbe then only add metadata for that table [:D]
Dynamic DataDynamicDataFiltering
See my blog C# Bits | Twitter @sjnaughton Always seeking an elegant solution.
Im playing with Northwind and I got one more. Now I have created Order_Details.cs in my App_Code folder. No Filters is showing up. Orders.cs works perfect and I cant understand what im doing wrong here
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel;
using Catalyst.ComponentModel.DataAnnotations;
[MetadataType(typeof(Order_DetailsMD))]
public partial class Order_Details
{
public class Order_DetailsMD
{
public object OrderID { get; set; }
public object ProductID { get; set; }
public object UnitPrice { get; set; }
public object Quantity { get; set; }
public object Discount { get; set; }
}
}
kisyv
Member
5 Points
16 Posts
Modify Default.aspx to list recent changes
Nov 15, 2009 04:28 PM|LINK
Im playing with DD Linq-to-SQL and started thinking of having a "recent 10 DVDs in my collection" list in the Default.apsx
What is the easiest way to do this?
sjnaughton
All-Star
27320 Points
5459 Posts
MVP
Re: Modify Default.aspx to list recent changes
Nov 15, 2009 10:25 PM|LINK
That all depends on how you are determining which the most recent DVD [:D] if you are using a date field then you could look at implementing a top ten filter in dd Preview 4 or DDv2 in VS2010 Beta 2.
There is not much that will enable you to do this (if I am understanding what you want) in DDv1.
Dynamic Data
Always seeking an elegant solution.
kisyv
Member
5 Points
16 Posts
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 06:04 PM|LINK
I see. Im currently not using DDv2. Thanks for the help.
sjnaughton
All-Star
27320 Points
5459 Posts
MVP
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 07:01 PM|LINK
There is antoher way if you are using Linq to SQL then Josh Heyes' Dynamic Data filtering on codeplex here:http://dynamicdatafiltering.codeplex.com/ may help, as this implements something alin to the new stuff but only for L2S though [:D] see my article here for installation: http://csharpbits.notaclue.net/2009/01/dynamic-data-filtering-installation.html
Hope this helps [:D]
Dynamic Data DynamicDataFiltering
Always seeking an elegant solution.
kisyv
Member
5 Points
16 Posts
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 07:39 PM|LINK
Wow! That looks awesome. But I have one question for now. I have my site on a local server here, and im creating this site on my desktop computer. After I have published the project, do the
<div>Dynamic Data Filtering 1.10 have to be installed on the server to make this work?</div><div></div><div>Thanks
</div>
sjnaughton
All-Star
27320 Points
5459 Posts
MVP
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 07:58 PM|LINK
When you add the a control via the toolbox the references are all added so no need to install on server [:D]
Dynamic Data DynamicDataFiltering
Always seeking an elegant solution.
kisyv
Member
5 Points
16 Posts
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 08:12 PM|LINK
Just tried it and it works
But I got a question. Do I have to make a partial classfile for all tables I have now, or is it possible to just enable this to one or two tables if I Create custom sites?
sjnaughton
All-Star
27320 Points
5459 Posts
MVP
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 09:36 PM|LINK
no you can create them pice meal just add each class as you need it [:D] so it you only need to add filters to one talbe then only add metadata for that table [:D]
Dynamic Data DynamicDataFiltering
Always seeking an elegant solution.
kisyv
Member
5 Points
16 Posts
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 09:49 PM|LINK
Im playing with Northwind and I got one more. Now I have created Order_Details.cs in my App_Code folder. No Filters is showing up. Orders.cs works perfect and I cant understand what im doing wrong here
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel;
using Catalyst.ComponentModel.DataAnnotations;
[MetadataType(typeof(Order_DetailsMD))]
public partial class Order_Details
{
public class Order_DetailsMD
{
public object OrderID { get; set; }
public object ProductID { get; set; }
public object UnitPrice { get; set; }
public object Quantity { get; set; }
public object Discount { get; set; }
}
}
Any help?
sjnaughton
All-Star
27320 Points
5459 Posts
MVP
Re: Modify Default.aspx to list recent changes
Nov 21, 2009 10:26 PM|LINK
Try:
using Catalyst.ComponentModel.DataAnnotations; [MetadataType(typeof(Order_DetailsMD))] public partial class Order_Details { public class Order_DetailsMD { public object OrderID { get; set; } public object ProductID { get; set; } public object UnitPrice { get; set; } [Filter(FilterMode = FilterControlMode.Contains)] public object Quantity { get; set; } public object Discount { get; set; } } }Hope this helps...
Dynamic Data DynamicDataFiltering
Always seeking an elegant solution.