I have following class structure
public class Limit
{
public double MinSelectedValue;
public double MaxSelectedValue;
public double MinValue;
public double MaxValue;
}
public class Limits
{
public Limit Standard;
public Limit Critical;
public string Name;
public string Unit;
}
I want to have a generic List of class Limits. My question is how to assign values to variables of type ‘Limit’ in class Limits.
Thanks
Vivek
I thing you are using Java language so this answer was related to java language.
Suppose you define list like this way
and you want to assign the the value of the Limit object into the Limits class. First define the Limit class object
now define the Limits class object like way
now add this limits object to the list like this way