I'm facing one issue in LINQ
string filter ="MediCare"; //dynamic(not constant)
var data = GetInsurancePlanList(InsurancefacilityId);
here i'm getting the result
Now i'm trying to filter the result using the string name called filter.
grdInsurancePlans.DataSource = data.Where(p => p.PlanCode.Contains(filter.ToUpper()) || p.PlanType.Tostring().Contains(filter.ToUpper()));
I able filter the records using "PlanCode" property because "plancode" is a string anyway
My qusetion here is,
I not able filter the records using "PlanType"."PlanType" is an enum.....eventhought i converted to string like above,i couldn't get the results
If i'm worng in doing convertion,can u give a solution?