i have one excel document and multiple sheets.sheets have many columns and row.i upload the document into my project.and the multiple sheets is bind to tables(sheet name is set as table name) using for loop.after the bind i change the table name to source1,source2,source3 (three sheets). Now how to bind(merge) the three tables in single table (source1).
I have Tried:
i have tried to rename the all tables to same name but the duplicate table is not allowed.how to bind the same table.


Midhun TpRank #388 · 6.5K reputationPosted Aug 11, 2016, 6:00 AM EDT
RajaRank #1,035 · 1.9K reputationPosted Aug 11, 2016, 6:29 AM EDT
Midhun TpRank #388 · 6.5K reputationPosted Aug 11, 2016, 6:36 AM EDT
Midhun TpRank #388 · 6.5K reputationPosted Aug 11, 2016, 6:47 AM EDT
RajaRank #1,035 · 1.9K reputationPosted Aug 12, 2016, 3:38 AM EDT
Bikesh SrivastavaRank #108 · 20.3K reputationPosted Aug 12, 2016, 4:23 AM EDT
RajaRank #1,035 · 1.9K reputationPosted Aug 12, 2016, 5:19 AM EDT
Bikesh Srivastava
Can you Please elaborate.I have little bit confusion so only.RajaRank #1,035 · 1.9K reputationPosted Aug 15, 2016, 8:31 PM EDT
for (int k = 0; k < ds.Tables.Count; k++)
{
int c = k + 1;
string sheetname = ds.Tables[k].ToString();
if (ds.Tables[k].ToString() == "ExcelSheetName" + c)
{
ds.DataSetName = "Search"; ds.Tables[k].TableName = "Table" + c; ds.Tables["Table" + c].AcceptChanges();
}
}
Bhuvanesh MohankumarRank #310 · 8.1K reputationPosted Aug 16, 2016, 12:20 AM EDT
Vinay SinghRank #604 · 4K reputationPosted Aug 16, 2016, 12:29 AM EDT