I am doing some fluent markup for Kendo Chart Labels:
.Labels(x =>
x.DateFormats(formats =>
formats
.Days(MyFormat.DateReportByDay)
.Months(MyFormat.DateReportByMonth))
.Culture(Thread.CurrentThread.CurrentCulture)
And I get this error:
Compiler Error Message: CS1660: Cannot convert lambda expression to type 'bool' because it is not a delegate type
But if I use this code:
.Labels(x =>
x.DateFormats(formats =>
formats
.Days("dd")
.Months("MMM yy"))
.Culture(Thread.CurrentThread.CurrentCulture)
It works fine. My definition for the format variables is
public static class MyFormat
{
public const string DateReportByMonth = "MMM yy";
public static string DateReportByDay = "dd";
}
It's saying I can't use a string constant in place of a string?? This is madness!
Model, as you haveModel.DayFormatin your Linq expression, butMyABDRFormat.DateReportByDay. - Sven Grosen