Globalization on Filemanager
I'm successfully using the Filemanager on Blazor Server 19.1.0.55 showing an ftp server content but if there are inside some specific files I received the error message in attachment and the filemanager is not showed at all (The DateTime represented by the string 'Mar 30 09:10' is not supported in
calendar 'System.Globalization.GregorianCalendar')
Attachment: Cattura_219b61a8.zip
It seems to be a problem in the file date and time format and specifically when the creation date or the last access date or the modification date is in March (Marzo in Italian language)
I suspect something wrong to identify Mar as March and confuse Mar as Martedi (Martedì is Tuesday in Italian language)
I followed your suggestion in the documentation page (Localization in Blazor - Syncfusion) to change the localization to Italian language and all the labels are now correctly showed in Italian but only when I removed the files related in some way to March the filemanager returned to work correctly
How can I solve this problem ?
Attachment: Cattura_219b61a8.zip
SIGN IN To post a reply.
5 Replies
1 reply marked as answer
IL
Indhumathy Loganathan
Syncfusion Team
April 13, 2021 10:42 AM UTC
Hi Walter,
Greetings from Syncfusion support.
We have validated your query in FileManager component with the provided details but unable to reproduce the reported issue in our end. We have prepared a Blazor FTP provider localization sample with 19.1.55 package version. The month March is converted to Marzo in Italian language. Please check the below screenshot.
|
|
You can find the sample demonstrating the solution from below link.
Please replace the locale files of your sample with our sample locale files and confirm if you are able to reproduce the issue. If the issue still persist, share us your complete code snippet or reproduce the issue in the above sample to proceed further.
Please let us know if you need any further assistance.
Regards,
Indhumathy L
WM
Walter Martin
April 14, 2021 08:51 AM UTC
Thanks for your reply
Attachment: Desktop_7af55135.zip
I used your demo changing only the line to set the ftp connection and I saw something I didn't notice before.
The files from my ftp server are all showed with a wrong modified date. It's always the current date with also a wrong time as you can see from my attachment.
I think there's nothing I need to check in my NAS where I have the ftp server running if you don't have any other ideas.
Some days ago I had surely a different situation because some of the files were red with the right month: "March" and not showed because of the error message of my first post so I don't really understand the source of problem
Even if I change the culture to English all the files are showed as "14 of April"
I'll try to investigate
Attachment: Desktop_7af55135.zip
KR
Keerthana Rajendran
Syncfusion Team
April 15, 2021 06:13 AM UTC
Hi Walter,
The FileManager demo sample shared in our previous update works fine with our FTP server and you can refer our previous screenshot shared for this. We suspect the issue occurs specific to your FTP server. Please investigate this at your end and get back to us with some clear details on your exact issue which will help us to assist you promptly.
Regards,
Keerthana.
WM
Walter Martin
April 29, 2021 12:23 PM UTC
I found the source of problem and the solution to anyone can be interested on
Attachment: FTPFileProvider_f89ef7d9.zip
The problem is what the LIST command returns in a ftp server with Unix OS
Surprisingly it returns the file details without the year information if it's the current one
This is a sample of what I received from my ftp server
-rw-rw---- 1 utenteftp everyone 234752 Apr 15 01:14 0000000072.zip
-rw-rw---- 1 utenteftp everyone 234752 Apr 25 01:10 0000000073.zip
Based on this information, the line of code 1380 of the attachment worked fine for the first line above but failed for the second line because 25 is parsed as the "hour" part of the time information so it's wrong. this is why I had problems only in particular files.
I solved the problem replacing line 1380 with the lines from 1376 to 1379
Attachment: FTPFileProvider_f89ef7d9.zip
Marked as answer
KR
Keerthana Rajendran
Syncfusion Team
April 30, 2021 06:37 AM UTC
Hi Walter,
Thanks for the update. We are glad to hear that the issue has been resolved. Please get back to us if you need further assistance. We will be happy to assist you.
Regards,
Keerthana.
SIGN IN To post a reply.
- 5 Replies
- 3 Participants
- Marked answer
-
WM Walter Martin
- Apr 9, 2021 07:22 AM UTC
- Apr 30, 2021 06:37 AM UTC