3
Neden "ondalık" geçerli bir özellik parametre türü değil?
Gerçekten inanılmaz ama gerçek. Bu kod çalışmaz: [AttributeUsage(AttributeTargets.Property|AttributeTargets.Field)] public class Range : Attribute { public decimal Max { get; set; } public decimal Min { get; set; } } public class Item { [Range(Min=0m,Max=1000m)] //compile error:'Min' is not a valid named attribute argument because it is not a valid attribute …
139
c#
.net
attributes