There are two Generic list of Inspectors and InspectorRates.
RateType has three different values (0 = Not Select ,1 = Day Rate ,2 = Hourly Rates).
I want to show all inspectors with Day Type Rate first and then lowest rate. If user selects option "Hourly Rates" then list needs to be sorted by Hourly Rate and thenlowest rate. Not seleted rate will always be at the bottom.
I have tried LINQ but its not working.
listI.OrderBy(Function(i) i.DefaultRate.RateType = Rates.RateTypeEnum.Day_Rate).ThenBy(Function(i) i.DefaultRate.Rate)