public void MarketGetir() { // SqlCommand MarketBilgiGetir = new SqlCommand("Select * From Tbl_Market", connect.baglanti()); // SqlDataReader dr = MarketBilgiGetir.ExecuteReader(); // if (dr.Read()) // { // MarketAd = dr[1].ToString(); // MarketAdres = dr[2].ToString(); // Marketler.Add() // } // connect.baglanti().Close(); SqlCommand select = new SqlCommand("select * from tbl_market", connect.baglanti()); SqlDataReader Dtr = select.ExecuteReader(); while (Dtr.Read()) { Market market = new Market() { MarketAd = Dtr[1].ToString(), MarketAdres = Dtr[2].ToString() }; Marketler.Add(market); } }
private void lpkMarket_SelectionChanged(object sender, SelectionChangedEventArgs e) { Marketler Market = lpkMarket.SelectedItem as Marketler; if (Market != null) { MarketId = Market.MarketId; } }
private void lpkMarket_SelectionChanged(object sender, SelectionChangedEventArgs e) { Marketler Market = lpkMarket.SelectedItem as Marketler; if (Market != null) { txtMarketAd.Text = Market.MarketAdi; txtMarketAdres.Text = Market.Adres; MarketId = Market.MarketId; } }
private void lpkMarket_SelectionChanged(object sender, SelectionChangedEventArgs e) { Marketler Market = lpkMarket.SelectedItem as Marketler; if (Market != null) { MarketId = Market.MarketId; al.MarketUrunleriAsync(MarketId); al.MarketUrunleriCompleted += new EventHandler <MarketUrunleriCompletedEventArgs>(al_MarketUrunleriCompleted); } }