public UserDataCategory(UserDataCategory other) { _categoryID = other._categoryID; _name = other._name; _appliesTo = other._appliesTo; _appliesToName = other._appliesToName; _tabOrder = other._tabOrder; _icon = other._icon; _scope = other._scope; _tag = other._tag; // Copy the associated fields also foreach (UserDataField field in other) { this.Add(field); } }
// We sort based on tab order public int CompareTo(UserDataCategory obj) { return(_tabOrder.CompareTo(obj._tabOrder)); }