Binding List to GridView
You must use public properties for DataBinding. Update your class as follows:
public class CreditCard
{
public String A_Number { get; set; }
public String A_Name { get; set; }
public String A_Type { get; set; }
public String A_Owner_Type { get; set; }
public String Bank_City { get; set; }
public String Bank_State { get; set; }
public String Bank_ZIP { get; set; }
public String Balance { get; set; }
public String C_Username { get; set; }
public CreditCard() { }
}
You have defined your CreditCard
as an object with fields. Data binding can only be done with properties. So, you need to do something like this for all fields:
public String A_Number { get; set; }