I want to create a new type using anonymous types.
This is my code:
var t = paramaterList.Select(x => x).ToArray().Select(item => new
{
item,
});
I need to create properties for var t
based on the name of item.
For example:
if paramaterList.Select(x => x).ToArray()
contained 3 items:
FirstName, Surname, Age
This should create properties for each of those items:
paramaterList.Select(x => x).ToArray().Select(item => new
{
});