-
10 Jun 2009 8:50 AM #201
hi nige,
i tested your ux a bit more (i told you i like it before, but again: nice work!).
i am using firefox3.1 and data that should be utf-8 inside the datastores.
when exporting to excel, the part
made different results in the output with btoa and the directly posted method.Code:encode : (typeof btoa == 'function') ? function(input) { return btoa(input); } : function (input) { var output = ""; var chr1, chr2, chr3, enc1, enc2, enc3, enc4; var i = 0; input = utf8Encode(input); ...
in btoa seems to be just an encode to base64 without the utf8encode() before. so, with btoa special characters got "destroyed".
i just removed it therefore
the other thing is, that gridPlugins like rowNumberer cause troubles. as a kind of hotfix i count from column 1 instead of 0 all the times (since i always use the plugin).Code:encode : function (input) { var output = ""; var chr1, chr2, chr3, enc1, enc2, enc3, enc4; var i = 0; input = utf8Encode(input); ...
kind regards, tobiu
-
14 Jun 2009 11:51 PM #202
Hello Animal.
I try to use your code with my GridPanel where the data are loaded with Ext.data.HttpProxy.
When I click on the button Excel I have the following error with firebug :
Can you help me to resolve it.Code:[Exception... "'<error>' when calling method: [nsIContentHandler::handleContent]" nsresult: "0x805d0001 (<unknown>)" location: "<unknown>" data: no]
Thank you.
-
29 Jun 2009 4:14 PM #203
Russioan characters or other (non-european) languages
Russioan characters or other (non-european) languages
Does anybody know why the export2excel plugin causes problems with non-europpean characters, like russian ones? I thought that this should not be a problem using utg8 encoding.
Thanks for any help,
vietschv
-
7 Jul 2009 12:16 PM #204
Hi, I tried the next code for export to excel and runs on IE7, IE8 and FF
bbar in grid:Code:function export(dato){ if (!Ext.fly('frmDummy')) { var frm = document.createElement('form'); frm.id = 'frmDummy'; frm.name = id; frm.className = 'x-hidden'; document.body.appendChild(frm); } Ext.Ajax.request({ url: 'export_excel.php', method : 'POST', form: Ext.fly('frmDummy'), callback: function(o, s, r){ alert(r.responseText); }, isUpload: true, params: { ex: dato } }); }
See ya!!Code:bbar: new Ext.Toolbar({ buttons: [{ id: 'grid-excel-button', text: 'Exportar a Excel', handler: function(){ var exportContent =grid.getExcelXml(); export(exportContent); } }] }),
PD: my english is bad
-
15 Jul 2009 4:42 AM #205
Any news to this IE bugg?
Any news to this IE bugg?
Hy guys. It's been a while from the first recording of this problem:
Default Error in IE8
Hi All,
Export to Excel works fine in FF, but in IE8 I get this error -
Message: The data area passed to a system call is too small.
Can anybody please tell me how to fix this?
and I still face this. Dear Animal, are u kind to give us an update about this? Stil no fix for it? Your last update about this:
Report it to McSoft. I would guess it's an IE error caused by using a data: URL. If it's a large dataset, then the BASE64 encoding of an XML spreadsheet will be large. The whole content is encoded into the href of a link as the URL. Looks like IE8 just cannot cope.
Maybe I missed something from the thread?
Thank you for your constant support!
-
4 Aug 2009 6:47 AM #206
-
11 Aug 2009 9:53 AM #207
The first post is a little misleading. I assumed it would work in IE8 due to the first comment. I then skimmed the 21 pages to see if there was any response to a positive IE8, now I suspect no one can get it working in IE8. After quite a bit of testing and searching to figure this out it appears IE8 doesn't support data URIs for this situation.
IE8 only allows for data URIs in img tags and CSS. I simply tested by attempting to enter the data directly into the navigation bar with no luck for IE8 and I finally found this Mozilla article to confirm it: https://developer.mozilla.org/en/The_data_URL_scheme
A MSDN reference: http://msdn.microsoft.com/en-us/libr...8VS.85%29.aspx
Data URIs cannot be used for navigation
-
17 Aug 2009 12:31 AM #208
XML Problem with 3.0 Grids
XML Problem with 3.0 Grids
Hello All,
I seem to be getting errors when I open up the worksheet in Excel. I've reviewed the log files and found the following.
I've recently upgraded all my grids to 3.0 to take advantage on some of the new features.
I'm using Office 2007, including the Formating pack and still I can't get this plugin to work with Grids 3.0.
Can anybody offer any assistance?? Here is snippet of my log file.
Thanks in advance.
Jack
I take it that it has to do with the part of the code which generates the cell data. I have not found anything but it seems that "odd" and "even" are undefined.Code:XML ERROR in Table REASON: Bad Value FILE: C:\Users\JanS.OSWORILOCAL\Desktop\something.xls GROUP: Cell TAG: Data ATTRIB: Type VALUE: undefined XML ERROR in Table REASON: Bad Value FILE: C:\Users\JanS.OSWORILOCAL\Desktop\something.xls GROUP: Row TAG: Cell ATTRIB: StyleID VALUE: evenundefined XML ERROR in Table REASON: Bad Value FILE: C:\Users\JanS.OSWORILOCAL\Desktop\something.xls GROUP: Cell TAG: Data ATTRIB: Type VALUE: undefined XML ERROR in Table REASON: Bad Value FILE: C:\Users\JanS.OSWORILOCAL\Desktop\something.xls GROUP: Row TAG: Cell ATTRIB: StyleID VALUE: oddundefined
Code:// Generate the data rows from the data in the Store for (var i = 0, it = this.store.data.items, l = it.length; i < l; i++) { t += '<ss:Row>'; var cellClass = (i & 1) ? 'odd' : 'even'; r = it[i].data; var k = 0; for (var j = 0; j < cm.getColumnCount(); j++) { if (includeHidden || !cm.isHidden(j)) { var v = r[cm.getDataIndex(j)]; if (cellType[k] !== "None") { t += '<ss:Cell ss:StyleID="' + cellClass + cellTypeClass[k] + '"><ss:Data ss:Type="' + cellType[k] + '">'; if (cellType[k] == 'DateTime') { t += v.format('d/m/Y'); } else { t += v; } t +='</ss:Data></ss:Cell>'; } k++; } } t += '</ss:Row>'; }
-
17 Aug 2009 6:25 AM #209
I think you're missing the styles that define even/odd.
Code:'<ss:Style ss:ID="even">' + '<ss:Interior ss:Pattern="Solid" ss:Color="#CCFFFF" />' + '</ss:Style>' + '<ss:Style ss:Parent="even" ss:ID="evendate">' + '<ss:NumberFormat ss:Format="[ENG][$-409]dd\-mmm\-yyyy;@" />' + '</ss:Style>' + '<ss:Style ss:Parent="even" ss:ID="evenint">' + '<ss:NumberFormat ss:Format="0" />' + '</ss:Style>' + '<ss:Style ss:Parent="even" ss:ID="evenfloat">' + '<ss:NumberFormat ss:Format="0.00" />' + '</ss:Style>' + '<ss:Style ss:ID="odd">' + '<ss:Interior ss:Pattern="Solid" ss:Color="#CCCCFF" />' + '</ss:Style>' +
-
19 Aug 2009 2:52 AM #210
Hi All,
Found what the issue was, the header were ignoring the cellRenders such as NumberedRow/CheckBox Slection, but inside the data is was actually counting from the rendered cell which means that the last cell was always undefined.
I used one of the simple fixes suggested by one of the posters and started to count from 1 rather then zero.
Thanks
Jack
Code://Around line 220 // ORIGINAL // Generate the data rows from the data in the Store for (var i = 0, it = this.store.data.items, l = it.length; i < l; i++) { t += '<ss:Row>'; var cellClass = (i & 1) ? 'odd' : 'even'; r = it[i].data; var k = 0; for (var j = 1; j < cm.getColumnCount(); j++) {


Reply With Quote
