C
C#2y ago
murtruby

No applicable method 'Contains' exists in type 'String' (at index 31) when using KendoNet.DymaicLinq

I have a a web app that I've built using Kendo's component library and I'm trying to introduce backend paging, sorting, and filtering. The problem is when Kendo is calling the DynamicLinq IQueryable Where extension method it's throwing the above error when using string operations not just contains. An example of the string it uses for the predicate is "((LastName != null && LastName.Contains(@0)))". I've tested this without the surrounding brackets and it still runs but throws the same error. I've included a screen shot that shows how the predicate is built.
2 Replies
Anton
Anton2y ago
idk the cause of your issue but some suggestions use StringBuilder if you can help it. your string allocations must be over the roof rn String.Join works with IEnumerable
Accord
Accord2y ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server
More Posts
❔ string modifyhow can i transform string like this `1234 5678 9123 4567` to this `1234 **** **** 4567` in a lambda❔ How to differentiate in C#?How can I differentiate a function like: "f(x)=sqrt(ax^2+b+cx)+gx+p+...etc" and every time it loops ✅ Problem With MYSQL Connection Using Entity FrameworkHello all, I am having problems to connect MYSQL. I think it can be related with my connection strin❔ About .NET Forms in Resources.resx files, what is the cost of removing PublicKeyToken?Second time in a couple months where my project breaks PublicKeyToken thanks to VisualStudio updatesautomated event handleri'm trying to index my bot's client with an event name but it throws an error, what's a way i can ac❔ is it possible to add // at beginning of text line when caret is in current line?Hello all, in a RichTextBox I split text by line, but I need to add the symbol **//** at the beginni✅ Schedule event at future DateTime based on DateOnly input, doesn't work if called <2min before```public static void ScheduleMethod(DateOnly inputDate) { DateTime triggerTime = new Da❔ Is something like this possible with the default DI package?So what I want to do is like this How scopes work normally: - global scope - scope 1 * duplicate methods from .GetMethods()```cs public ElfinCommand[] ReadCommands() { List<ElfinCommand> commands❔ Message box using small Segoe UI/skinny/classic theme for OK buttonI am making a simple C# program with MessageBox.Show. When I run it I get a message box with the tex