Categories | Question details Back To List | ||
Export grid dat to an Excel file Hello , I ask if everyone of you know how in can export data from a grid to an Excell file ? Thanks in advance. Answer posted by Stanislav on Dec 04, 2007 09:49 There is no way to export directly to Excell, but grid can be serialized to XML or CSV string ( which can be opened by Excel ) If you will need to send the result file back to user, the process will look as a) serialize file to csv string b) send it back to server c) server returns same data with correct content type Answer posted by Bahae Eddine on Dec 04, 2007 10:16 Hello, a lot of Thanks to you . I'm still thinking to serialize data of the grid to CSV ,it works but what i need is i should have some toolbar in which i will have the possibility to read this file with the microsoft Excell .in other words i wish have an Excell file format. Any help
Answer posted by Support on May 19, 2008 06:17 Native Excel format is binary, so you will need some kind of server processing in any case, it can be formed fully on client side. ( probably it can't, but it is non trivial task ) Answer posted by Bahae Eddine on Dec 04, 2007 10:25 Have any example for doing this ?
Answer posted on Dec 05, 2007 01:32 There is no examples of such client side code, but I can send you an example of CSV-excell code ( javascript + PHP ) Answer posted by Chien Hoang on Jan 08, 2008 15:08 Hi Bahae, I raised this question long time ago. Actually, we can do it from client-side with Automation server. I posted an exemple here and it worked. Good luck, -Chien Hoang function toExcel(){ Answer posted by Brian on Feb 20, 2008 13:26 Are there any examples that I can get using PHP & javascript? Answer posted by Hans on May 18, 2008 13:08 I think Stanislav's answer is the right way to do it. Writing a server page that outputs data to Excel is very easy and works on most platforms. Chien's solution is using ActiveXobject which works in IE only, and will most probably make Excel hang on the client machine. Especially after a couple of attempts.
|