I am display data in gridview, that has paging. when exporting to excel,all entries are not coming.Suppose I click on page1, then all entry from page1,not all pages.Then I have to click on page2,for page2 entry.Does all entry from all pages will come in single click on button.Does it right way,I don't know.
2 Answers
You would need to pass the entire dataset to your export function, instead of the filtered one that I am assuming you are passing currently.
7 Comments
Jui Test
In one function suppose f1(), I am executing a query.Taking that value in dataset and assign dataset object to gridview and bind.Call f1 in starting of function f2(where I writing code for export).
jgallant
The query you are executing is returning a full dataset or a partial dataset? You may need to write another query to retrieve the full dataset before exporting it.
Jui Test
See I have done like this(sample query).Select col1,col2,col3 from table1 inner join table2 on table1.id =table2.id where table.id='34'.Taking that value in dataset and assign dataset object to gridview and bind.Gridview has default page size is 10.How many record can we take in one excel file.
jgallant
65534 records maximum in an excel file.
Jui Test
Hey Jon,thanks.In some query more than 1000 record means have to come all data together.No need to click on second page ,right?But this not happening in my case.
|