CodingC#- classes inside classes... or something
private string m_AffiliateName;
if (target.GetType() == typeof(System.DateTime)) { target = DateTime.Parse(nav.Value); } else { target = nav.Value; }
public class AffiliateFilters { AffiliateConstants _parent; public AffiliateFilters(AffiliateConstants parent) { _parent = parent; } public DateTime StartDate { get { return _parent.m_FilterStartDate; } } public DateTime EndDate { get { return _parent.m_FilterEndDate; } } public String MetroCode { get { return _parent.m_FilterMetroCode; } } public String ZipCode { get { return _parent.m_FilterZipCode; } } }
No, that'd be fine too.
Are you using some ancient version of C#? Maybe the compiler wasn't as clever before 3.0 or something.
I'm on Visual Studio 2008 but it's targetting 2.0, so that's possibly the case.
At least I'm not using 1.1 any more. Slow progress.