0

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 2

1

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.

Sign up to request clarification or add additional context in comments.

7 Comments

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).
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.
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.
65534 records maximum in an excel file.
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.
|
0

In your export function, disable paging on the grid and rebind it. Afterwards, just turn paging back on and rebind it again.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.