幫看看 這段listbox顯示的問題
private void button20_Click(object sender, EventArgs e)//点击 后台总金{
this.sqlConnection1.Open();
SqlCommand sqlcon5 = new SqlCommand();
sqlcon5.Connection = this.sqlConnection1;
= "select Maccount from M_account";
SqlDataReader dr = sqlcon5.ExecuteReader();
while (dr.Read())
{
this.ATMMessagelistBox1.Items.Add(dr[0].ToString);
}
this.sqlConnection1.Close();
}
這是ATM查詢金額的button 想實現在listbox顯示出來 但是有錯誤 幫忙看看