Talha Hüner
Asp Veri Ekleme
using System;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using System.Data.OleDb;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void TextBox2_TextChanged(object sender, EventArgs e)
{
}
protected void TextBox1_TextChanged(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
OleDbConnection baglan = new OleDbConnection("Provider=Microsoft.Jet.Oledb.4.0;Data Source=" + Server.MapPath("App_Datavt.mdb"));
baglan.Open();
OleDbCommand komut = new OleDbCommand("insert into Tablo1 (Adsoy,numara) values(@Adsoy,@numara)", baglan);
komut.Parameters.AddWithValue("@Adsoy", TextBox1.Text);
komut.Parameters.AddWithValue("@numara", TextBox2.Text);
komut.ExecuteNonQuery();
baglan.Close();
}
}
------------------------------------------ekran çıktısı
ad soyad :
|
Bugün 10 ziyaretçi (31 klik) kişi burdaydı!