开发者

Default value as display value c#

I am getting products in JSON format and I want that my default product have a开发者_如何学Go MARK that I know that is default:

DisplayValue = "MARK";

How can I do it?


In javascript you can add a property to any object just by assigning a value:

var products = [{ Name: 'A' }, { Name: 'B' }, { Name: 'C' }];

$(products).each(function() {
    this.DisplayValue = "MARK" + this.Name;
}
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜