Getting dropdown property value from descendant

Hi All,

Can someone please explain why this works. I want to retrieve all property listings where the proeprtyCategory value is set to ‘To Let’ in a drop down data type

var propertiesToLet = Model.Content.Descendants("propertyListingPage").Where(x => x.GetPropertyValue<bool>("propertyCategory")).ToList().OrderBy("CreateDate desc");

and this doesnt

var propertiesToLet = Model.Content.Descendants("propertyListingPage").Where(x => x.GetPropertyValue<string>("propertyCategory == To Let")).ToList().OrderBy("CreateDate desc");

many thanks

Paul


This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/75457-getting-dropdown-property-value-from-descendant