forum

home / developersection / forums / how to convert lambda expression to func<> variable

how to Convert Lambda expression to Func<> variable

Anonymous User 3629 18-Aug-2014

I have code for searching file. And now have Lambda Expression for filtering that.How to convert the Expression to Func<string> variable. Thanks

Code :

Directory.GetFiles(folder, "*" + KeyWord +
"*").Where(f =>formatFile.Contains(f.Split('.').Last().ToLower()));
into variable :
Func<string> Lambda = ?? (f =>formatFile.Contains(f.Split('.').Last().ToLower())) \\ convert the Expression;

c# c# 
Updated on 18-Aug-2014

I am a content writter !


Message
Can you answer this question?

Answer

1 Answers

Liked By