val = dr[param].ToString(); System.Type type = this.GetType().GetField(param).GetType(); this.GetType().GetField(param).SetValue(this, (type)val);