Excel crashes when I try to change the codename of a worksheet

eirikdaude

Board Regular
Joined
Nov 26, 2013
Messages
93
Office Version
  1. 365
Platform
  1. Windows
I have a worksheet in which the sheets have different codenames. Earlier it has worked fine, but on getting a new computer, some of the codenames aren't showing up as they should any longer. When I try to change the codenames of these sheets, the field for the codename goes blank, Excel hangs for a little while, and then closes.

1638946904627.png


From what I understand one possible cause for this may be that I don't have the same charsets installed on this computer as I used to have. Does anyone here know how I check what charsets I have installed, or possibly how I change the codenames of the sheets without crashing Excel?
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.
Your issue has imo nothing to do with the installed fonts, rather with the installed code page which depend on the regional settings of the Windows OS on your system.
Apparently those settings are different from those on your previous computer.
With the steps below you can find out the current setting and change this as well. You need Administrator privileges for that.
- Open Windows Control Panel;
- Select Region (and Language);
- Click on the Administrative tab;
- Under Language for non-Unicode programs section click Change System Locale button;

More about code pages:

See whether this helps you.
 
Upvote 0
Your issue has imo nothing to do with the installed fonts, rather with the installed code page which depend on the regional settings of the Windows OS on your system.
Apparently those settings are different from those on your previous computer.
With the steps below you can find out the current setting and change this as well. You need Administrator privileges for that.
- Open Windows Control Panel;
- Select Region (and Language);
- Click on the Administrative tab;
- Under Language for non-Unicode programs section click Change System Locale button;

More about code pages:

See whether this helps you.
Hi, and thanks for your reply. I just checked, and the setting for this is "Norwegian (Nynorsk)", which I would assume included the characters in question. Do you have any further suggestions for what might cause the issue?
 
Upvote 0
You could check whether the actually active code page is the correct one. Judging by this table that would have to be either 1142 or 20277.
You can do such a check by opening a Windows Command Console and then entering the command CHCP. The number of the active code page is then displayed.
You can change the active code page with:
chcp 1142
or
chcp 20277

If this doesn't solve the problem then I'm afraid the last option is to look in the file itself (using a low-level file editor) to see if any recovery is possible.
The latter approach is not a guarantee of success, however.
 
Upvote 0
Solution
You could check whether the actually active code page is the correct one. Judging by this table that would have to be either 1142 or 20277.
You can do such a check by opening a Windows Command Console and then entering the command CHCP. The number of the active code page is then displayed.
You can change the active code page with:
chcp 1142
or
chcp 20277

If this doesn't solve the problem then I'm afraid the last option is to look in the file itself (using a low-level file editor) to see if any recovery is possible.
The latter approach is not a guarantee of success, however.
Thanks. I had a look and it returns 65001 - utf-8, which I assume is because "Beta. Use Unicode UTF-8 for worldwide language support" is checked. I tried unchecking this, which changed the character code page to 850 (OEM Multilingual Latin 1; Western European (DOS)).

This seems to have solved the problem, I guess the VBE had some trouble with the UTF-8 code page, and was defaulting to some page which did not contain the characters I needed. Thanks a lot for your help, it really is a relief to get this to work.

As you also suggest in your post, I had already had a look at the xml-files of the workbook, and tried to change the name in some locations, but I hadn't found them all and was not looking forward to trying to find them.
 
Upvote 0
You're welcome and thanks for the follow-up (y)
Glad your issue is solved.
 
Upvote 0

Forum statistics

Threads
1,215,018
Messages
6,122,703
Members
449,093
Latest member
Mnur

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top