c# - CustomAttribute with property that is a AttributeTarget property name as string -


i want change customattribute usage in way, i'm using refer search parameters of autocomplete dropdown

now:

[entitysearchdropbox(id="id",searchcolumns="name")] public virtual class mytarget 

but hate strings defining entity properties , best solution me passing attributetarget property without writing free strings.

[entitysearchdropbox(id=mytarget.id,searchcolumns=mytarget.name)] public virtual class mytarget 

mytarget example

public class mytarget{     public int id    {get; set;}     public string name  {get; set;}     public string otherproperty { get; set; }     //etc..   } 


Comments

Popular posts from this blog

matlab - "Contour not rendered for non-finite ZData" -

delphi - Indy UDP Read Contents of Adata -

javascript - Any ideas when Firefox is likely to implement lengthAdjust and textLength? -