Quantcast
Channel: ClearScript
Viewing all articles
Browse latest Browse all 2297

New Post: Running List ForEach using script

0
0
I have an existing List<string> which is passed into the engine as an object.
engine.AddObject("Datas", datas);
This is the script that i want to execute
Datas.ForEach(function(d){
//read the string here
});
When i try to execute the it using a function, it throws an error "The best overloaded match for List<string>.ForEach(System.Action<string>) has some invalid arguments".

I guess that the javascript function is not transform into C# Action?

Viewing all articles
Browse latest Browse all 2297

Latest Images

Trending Articles





Latest Images