In a development that I am doing, I create a type of object from one of my classes that are stored in my library in the following way:
var type = GetTypeFromAssembly(typeName, fullNameSpaceType);
var instanceOfMyType = Activator.Crea...
I am practicing Lambda expressions and I have the following.
I have a person class:
private static class Persona {
public int a;
public String b;
public Persona(int a,String b){
this.a=a;
this.b=b;
}
pub...
I have a list of objects
List<Objeto> lista1;
List<Objeto> lista1;
Object has an attribute X and an attribute Y .
I want to do the following:
List<Objeto> listaSuma => add the values Y o...
I'm working with lambda expressions but I have a problem
I have this method:
public static void Test_LambdaExpresions()
{
var albums = new List<Album>
{
new Album { Quantity = 10, Artist = "Betontod", Titl...
I want to do this in a code that only takes one line, who can help me would be great.
long processSize = 0;
Process bProcess = null;
foreach (var process in Process.GetProcessesByName(name).Where(x => x.PagedMemorySize64 > processSize))...
I'm testing the Java 8 Lambda expressions.
In my code I create a list of objects that can be of type Person or type Employee .
The class Employee extends from Person and I want, using a lambda expression to displ...
Case 1:
I have a List with a series of elements that can be repeated.
List<String> nombre;
nombre.add("Persona 1");
nombre.add("Persona 1");
nombre.add("Persona 1");
nombre.add("Persona 2");
nombre.add("Persona 3");
...
Is i...
I have this afternoon ...
void TareaFecha()
{
Task T = new Task(() =>
{
DateTime FechaActual = DateTime.Today;
DateTime Inicio = FechaActual.AddDays(8);
MessageBox.Show($"TareaFech...
I have a lambda function (arrow or anonymous function) in JavaScript , which declares a variable, but the problem is that it declares it as a global variable, and I I would like it to be local (only accessible within lambda).
(x=>(...
Good I need to show a count I am working with a listing and lambda as follows:
@foreach (var item in Denuncias)
{
var DenunciaPersona = dbDP.TraerTodo().Where(x => x.NODENUNCIA ==...