Is it possible something like this? I've worked hard, but I think it's not possible, I hope someone will help me.
I have to fill the object like this,
var obj = new
{
parentObj = new List<object>()
{
outsideArray.ForEach(x=>
{
})
}
}
I dont like this.
var obj = new
{
parentObj= new List<object>()
{
new object() { bla, bla }
}
}
I want to do.
var obj {
Id =1,
Name= "any",
Address = new {
userAddressList.forEach(x=> {
Town = x.town,
State = x.state
}
}
}