Exporting to CSV file using uiGridExporter , NOT working in IE 11
I am trying to use the Export feature provided by UI Grid, but, export to CSV file is not working in IE 11. But the same works in Fire fox. Please try opening the plunker in IE
http://plnkr.co/edit/en4c9DZ3308h4MhSqrZi?p=preview Need your attention on the mentioned issue. Thanks
Unfortunately I don't have IE11, and I don't think many of the other devs do either. That means you'll need to do a bit more diagnostics on your own to provide information.
Where exactly does it throw errors (if anywhere). Does it create the docObject, is it the same on Firefox and on IE11? There is specific IE logic in the code, does it correctly detect IE and enter that logic? Does that logic work as expected? If not, is there information on the web about some new change in IE that would have broken that logic?
Hi PaulL1,
I am also facing the same issue , I saw it working in the 3.0.1 version , but it is not working in 3.1.1 .
The issue seems to be the isIE function has been revised in 3.1.1 which is not returning 11 as before. I tried using the old isIE function in 3.1.1 , it works in IE11.
isIE() in 3.0.1.:
isIE: function () { var match = navigator.userAgent.match(/(?:MSIE |Trident\/.*; rv:)(\d+)/); return match ? parseInt(match[1]) : false; },
isIE() in 3.1.1 :
isIE: function () { var match = navigator.userAgent.search(/(?:Edge|MSIE|Trident\/.*; rv:)/); var isIE = false; if (match !== -1) { isIE = true; } return isIE; },
OK, I didn’t do that change, but I can see that the match string looks a bit different than before, clearly aiming to cover Edge as well as IE. Perhaps see if you can adjust the match string for the 3.1.1 version to correctly detect IE 11 whilst not breaking the other variants?
Paul Lambert Program Director NTS 021 385 488
From: Bharathjt <[email protected]mailto:[email protected]> Reply-To: angular-ui/ui-grid <[email protected]mailto:[email protected]> Date: Monday, 18 April 2016 at 6:01 PM To: angular-ui/ui-grid <[email protected]mailto:[email protected]> Cc: Paul Lambert <[email protected]mailto:[email protected]> Subject: Re: [angular-ui/ui-grid] Exporting to CSV file using uiGridExporter , NOT working in IE 11 (#5321)
Hi PaulL1, I am also facing the same issue , I saw it working in the 3.0.1 version , but it is not working in 3.1.1 . The issue seems to be the isIE function has been revised in 3.1.1 which is not returning 11 as before. I tried using the old isIE function in 3.1.1 , it works in IE11. isIE() in 3.0.1.: isIE: function () { var match = navigator.userAgent.match(/(?:MSIE |Trident/.; rv:)(\d+)/); return match ? parseInt(match[1]) : false; }, isIE() in 3.1.1 : isIE: function () { var match = navigator.userAgent.search(/(?:Edge|MSIE|Trident/.; rv:)/); var isIE = false; if (match !== -1) { isIE = true; } return isIE; },
— You are receiving this because you commented. Reply to this email directly or view it on GitHubhttps://github.com/angular-ui/ui-grid/issues/5321#issuecomment-211217979
The current isIE() function now can only return true or false, and it returns true for all versions of IE and Edge.
In the downloadFile() method the returned value is used here:
ieVersion = this.isIE();
if (ieVersion && ieVersion < 10) { ... }
ieVersion < 10 evaluates to true if ieVersion is true, so the code intended for IE9 and below is called for all versions of IE.
Reverting to the old isIE method from 3.0.1 fixes this issue in Edge, IE11 and IE10.
Thanks for contributing! This repository has been transferred, and we're preparing the new 5.x release. We're closing older issues and pull requests as part of the reset. Please join us on Discord to follow the work or continue the conversation: https://discord.gg/Baz4w8ZWN