Cannot export Unigrid data to .xls or .csv format

Arshad Nazeer asked on January 9, 2015 10:03

Hello everyone, I have a unigrid that looks like this: <ams:UniGrid runat="server" ID="grdData" IsLiveSite="false" GridName="../GridXmls/Data.xml" ShowActionsMenu="true"></ams:UniGrid> The Unigrid is showing Action menu but when I try to export to a .xls file it is showing me a pop-up with the following message: There are no data to export, please check your export settings. Please explain what needs to be done.

Thanks.

Correct Answer

Arshad Nazeer answered on January 9, 2015 12:07

I have resolved the issue by repopulating Unigrid after it makes a postback when clicked on Export To Excel. Earlier, during postback after I click on Export To Excel the Unigrid was getting emptied therefore there was a pop-up with the message.

Thanks.

0 votesVote for this answer Unmark Correct answer

Recent Answers


Radek Macalik answered on January 9, 2015 10:08

Hello.

Does your UniGrid display any data? How do you load data to that UniGrid? Could you please clarify this? Thank you.

Best regards, Radek Macalik

0 votesVote for this answer Mark as a Correct answer

Arshad Nazeer answered on January 9, 2015 10:18

I am successfully loading data in the Unigrid in the following manner: DataSet ds = new DataSet(); ds = Database.data(p, q); grdData.DataSource = ds; grdData.DataBind(); grdData.ReBind();

When data is present in the Unigrid I am clicking on Action Menu and then on Export To Excel but it shows a pop-up with message: There are no data to export, please check your export settings.

0 votesVote for this answer Mark as a Correct answer

Radek Macalik answered on January 9, 2015 12:15

Hello.

Thank you for your update and for sharing the solution here.

Best regards, Radek Macalik

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.