ASP Sayfa1
ASP Sayfa1
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.ServiceModel.Channels;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Data.SqlClient;
lblKitalar.Text = "Kıtalar";
lBtnGirisFormu.Text = "Kullanıcı Girişi";
SqlDataReader veriOkuyucu;
sqlConnection.Open();
veriOkuyucu = sqlKomutuKitalar.ExecuteReader();
while(veriOkuyucu.Read())
{
ddListKitalar.Items.Add(veriOkuyucu[0].ToString());
}
sqlConnection.Close();
}
catch
{
Response.Redirect("Sayfa1BK.aspx");
}
}
}
//SqlDataAdapter
DataTable WebSunucusuVeriKumesi = new DataTable();
SqlDataAdapter veriTasiyici = new SqlDataAdapter(sqlKomutuUlkeler);
veriTasiyici.Fill(WebSunucusuVeriKumesi);
gViewUlkeler.DataSource = WebSunucusuVeriKumesi;
gViewUlkeler.DataBind(); //gridview kaynagındaki verinin grid view
aracılıgı ile ekrana yansıtılması