Nettiers.AdventureWorks.Entities.VAdditionalContactInfoBase.GetPropertyValueByName C# (CSharp) Method

GetPropertyValueByName() public static method

Gets the property value by name.
public static GetPropertyValueByName ( VAdditionalContactInfo entity, string propertyName ) : object
entity VAdditionalContactInfo The entity.
propertyName string Name of the property.
return object
		public static object GetPropertyValueByName(VAdditionalContactInfo entity, string propertyName)
		{
			switch (propertyName)
			{
				case "ContactId":
					return entity.ContactId;
				case "FirstName":
					return entity.FirstName;
				case "MiddleName":
					return entity.MiddleName;
				case "LastName":
					return entity.LastName;
				case "TelephoneNumber":
					return entity.TelephoneNumber;
				case "TelephoneSpecialInstructions":
					return entity.TelephoneSpecialInstructions;
				case "Street":
					return entity.Street;
				case "City":
					return entity.City;
				case "StateProvince":
					return entity.StateProvince;
				case "PostalCode":
					return entity.PostalCode;
				case "CountryRegion":
					return entity.CountryRegion;
				case "HomeAddressSpecialInstructions":
					return entity.HomeAddressSpecialInstructions;
				case "EmailAddress":
					return entity.EmailAddress;
				case "EmailSpecialInstructions":
					return entity.EmailSpecialInstructions;
				case "EmailTelephoneNumber":
					return entity.EmailTelephoneNumber;
				case "Rowguid":
					return entity.Rowguid;
				case "ModifiedDate":
					return entity.ModifiedDate;
			}
			return null;
		}
				

Same methods

VAdditionalContactInfoBase::GetPropertyValueByName ( string propertyName ) : object