C#專家能幫助我將此linq代碼轉換爲表達式樹嗎?將此linq代碼轉換爲表達式
var settingViewModels = from l in settingsByEnvironment["Localhost"]
from d in settingsByEnvironment["Dev"]
from p in settingsByEnvironment["Prod"]
where l.Key == d.Key && p.Key == d.Key
select new MyKeyValue
{
Key = p.Key,
LocalhostValue = l.Value,
DevValue = d.Value,
ProdValue = p.Value
};
謝謝!
嘗試使用http://msdn.microsoft.com/en-us/library/bb397951.aspx – Nahum