DataSet dsJobs = new DataSet(); DataTable jobs = new DataTable("Jobs"); private void Page_Load(object sender, System.EventArgs e) { if (!IsPostBack) { jobs.Columns.Add(new DataColumn("Name",typeof(string))); jobs.Columns.Add(new DataColumn("Surname",typeof(string))); } public void confirm() { DataRow rowJob = dsJobs.Tables["Jobs"].Rows.Add(new object [] {"jack","london"}); dsJobs.Tables.Add(jobs); dgJobs.DataSource = ds; Page.DataBind(); }