c# - How in Linq to entity replace true or false with On or Off? -
i need bind grid linq entity(asp c#), when im binding need replace true or false on or off. how can accomplish it?
ex.
var t = k in entity.table select k.isactive;
so in result if
isactive == true need return on
isactive == false need return off
var t = k in entity.table select k.isactive ? "on" : "off";
Comments
Post a Comment