static Type GetPropertyType(ProfileGroupSettings pgs, ProfilePropertySettings pps) { Type type = HttpApplication.LoadType(pps.Type); if (type != null) { return(type); } Type profileType = null; if (pgs == null) { profileType = ProfileParser.GetProfileCommonType(HttpContext.Current); } else { profileType = ProfileParser.GetProfileGroupType(HttpContext.Current, pgs.Name); } if (profileType == null) { return(null); } PropertyInfo pi = profileType.GetProperty(pps.Name); if (pi != null) { return(pi.PropertyType); } return(null); }
public ProfileGroupBase GetProfileGroup(string groupName) { ProfileGroupBase group = null; Type groupType = ProfileParser.GetProfileGroupType(HttpContext.Current, groupName); if (groupType != null) { group = (ProfileGroupBase)Activator.CreateInstance(groupType); } else { throw new ProviderException("Group '" + groupName + "' not found"); } group.Init(this, groupName); return(group); }