开发者

Problem with validation in asp.net mvc 3

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;
namespace Entit开发者_如何转开发ies.EntityExtensions
{
    [MetadataType(typeof(IncomeDeclaration_Validation))]
    public partial class IncomeDeclaration
    {
    }

    [Bind(Exclude="Id")]
    public class IncomeDeclaration_Validation
    {
        [Required]
        [StringLength(100)]
        public string Name;
    }
}

"Im getting a the type or namespace Bind is not defined" error... Im lost.

please help


You haven't included System.Web.Mvc namespace there...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜