wfsave command corrupts Excel file updating sheet whose name is in Japanese character

For notifying us of what you believe are bugs or errors in EViews.
Please ensure your copy of EViews is up-to-date before posting.

Moderators: EViews Gareth, EViews Moderator

watabehj
Posts: 28
Joined: Tue Apr 12, 2011 1:19 am

wfsave command corrupts Excel file updating sheet whose name is in Japanese character

Postby watabehj » Fri Oct 14, 2022 6:11 am

Hello. I am using Eviews13 (Standard Edition Oct 4 Build) and found that wfsave command corrupts Excel file when updating sheet whose name is in Japanese character. As an example, attached please find "wfsavetest1.prg", "wfsavetest2.prg", "wfsavetest3.prg" and "data1.xlsx", "data2.xlsx", "data3.xlsx".
wfsavetest1.prg updates sheet whose name is in Japanese character in data1.xlsx using legacy option (as suggested in viewtopic.php?f=9&t=21405). This works fine, as it does in EViews12 or earlier.
If you remove legacy option as in wfsavetest2.prg, it corrupts Excel file. The result is data2.xlsx. If you try to open this file, Excel says "We found a problem with some content in 'data2.xlsx'. Do you want to try to recover as much as possible? Click yes if you trust the source of the workbook", and if you click yes, Excel says that the file is unrecoverable.
However, if you try to update sheet whose name is in English as in wfsavetest3.prg, it works fine without legacy option even if the designated file contains the sheet whose name is in Japanese character as in data3.xlsx.
(BTW, when executing these programs several times, I occasionally encountered memory error reported in viewtopic.php?f=9&t=21388)
I know EViews doesn't officially support non-English environment, but we would be very grateful if you could fix this problem.

wfsavetest1.prg

Code: Select all

WFCREATE(WF=TMP,PAGE=Q)Q 2010 2030
series aaa=100
wfsave(type=excelxml, mode=update, nonames, legacy) data1.xlsx range=テスト!a2 @keep aaa

wfsavetest2.prg

Code: Select all

WFCREATE(WF=TMP,PAGE=Q)Q 2010 2030
series aaa=100
wfsave(type=excelxml, mode=update, nonames) data2.xlsx range=テスト!a2 @keep aaa

wfsavetest3.prg

Code: Select all

WFCREATE(WF=TMP,PAGE=Q)Q 2010 2030
series aaa=100
wfsave(type=excelxml, mode=update, nonames) data3.xlsx range=test!a2 @keep aaa
Attachments
data1.xlsx
(9.38 KiB) Downloaded 72 times
data2.xlsx
(8.17 KiB) Downloaded 68 times
data3.xlsx
(8.35 KiB) Downloaded 65 times

Return to “Bug Reports”

Who is online

Users browsing this forum: No registered users and 8 guests