private void button12_Click(object sender, EventArgs e) { List <string> lst = null; lst = quoteCom.GetETFStocks(tbetfcode.Text); lbETF.Items.Clear(); if (lst == null) { lbETF.Items.Add("查無資料,可能未連線/未下載/無此商品!!"); return; } string msg = "ETF [" + tbetfcode.Text + "] 成份股列表"; lbETF.Items.Add(msg); StringBuilder sb = new StringBuilder(); for (int i = 0; i < lst.Count; i++) { lbETF.Items.Add(lst[i]); } }