# (block.loc.LOCALE = blocksyntax) Does (zh-CN) are now supported?

**URL:** https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395
**Category:** micro:bit
**Created:** [April 15, 2021, 3:57pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395 "2021-04-15T15:57:04Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![Joel](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/joel/32/3929_2.png) [@Joel](https://forum.makecode.com/u/Joel)
#### Post date: [April 15, 2021, 3:57pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/1 "2021-04-15T15:57:04Z")

</div>

Hello, I use the (block.loc.LOCALE = blocksyntax) function to specify the local language as (zh-CN), but it has no effect, but it is normal to specify as (jp). The following are the codes of (zh-CN) and (jp) respectively:

zh-CN: //% block.loc.zh-CN=“test”

jp: //% block.loc.jp=“テスト”

(block.loc.LOCALE = blocksyntax) Does (zh-CN) are now supported?

In the case of Chinese, what value should be specified for LOCALE?

Thank you

---

<div class="post-metadata">

### Author: ![microbit-mark](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/microbit-mark/32/543_2.png) [@microbit-mark](https://forum.makecode.com/u/microbit-mark)
#### Post date: [April 16, 2021, 4:31pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/2 "2021-04-16T16:31:20Z")

</div>

I can reproduce this in the playground

 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/2X/a/adc980c076f2bc77984c044d9819e388d4049969.png)

The docs for this are here [https://makecode.com/defining-blocks#custom-block-localization](https://makecode.com/defining-blocks#custom-block-localization)

and it looks like zh-CN is the country code in Crowdin for Simplified Chinese.

@peli any thoughts?

---

<div class="post-metadata">

### Author: ![CleoQc](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/cleoqc/32/3941_2.png) [@CleoQc](https://forum.makecode.com/u/CleoQc)
#### Post date: [April 16, 2021, 4:32pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/3 "2021-04-16T16:32:22Z")

</div>

Hello @Joel

I have not tried it but it seems a 2 letter code would be required, since it uses a 2 letter code for Japanese.  
The 2 letter code for 汉语 is zh

I usually deal with En/Fr translations and I have not tried the inline translation, just the \_locale approach.

---

<div class="post-metadata">

### Author: ![Joel](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/joel/32/3929_2.png) [@Joel](https://forum.makecode.com/u/Joel)
#### Post date: [April 16, 2021, 6:21pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/4 "2021-04-16T18:21:02Z")

</div>

Thank you for your reply. I tried “zh” but it didn’t work. Specifying LOCALE as es-ES doesn’t take effect either. It may be a problem with “-”

---

<div class="post-metadata">

### Author: ![Joel](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/joel/32/3929_2.png) [@Joel](https://forum.makecode.com/u/Joel)
#### Post date: [April 16, 2021, 6:21pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/5 "2021-04-16T18:21:06Z")

</div>

Thanks for the reply, the LOCALE specified as es-ES also cannot take effect, it may be a problem with “-”

---

<div class="post-metadata">

### Author: ![jwunderl](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/jwunderl/32/5308_2.png) [@jwunderl](https://forum.makecode.com/u/jwunderl)
#### Post date: [April 16, 2021, 7:44pm UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/6 "2021-04-16T19:44:37Z")

</div>

Yeah, it’s fairly likely just a regex in the parsing of the failing localization attribute due to the dash – none of our other attributes use that so we might just be checking for valid letters + ‘.’ .

I filed a bug for this, will take a look before the next major release! [https://github.com/microsoft/pxt-microbit/issues/3985](https://github.com/microsoft/pxt-microbit/issues/3985)

---

<div class="post-metadata">

### Author: ![frank\_schmidt](https://avatars.discourse-cdn.com/v4/letter/f/7993a0/32.png) [@frank\_schmidt](https://forum.makecode.com/u/frank_schmidt)
#### Post date: [April 18, 2021, 2:18am UTC](https://forum.makecode.com/t/block-loc-locale-blocksyntax-does-zh-cn-are-now-supported/7395/7 "2021-04-18T02:18:41Z")

</div>

Hey, I have a question also about using Chinese. This may not be exactly what you are talking about but people in this conversation might know the answer. We have a video out showing Arcade with edge connector and a siren with flashing LED lights. The first words using ‘story’ say that it is a Police Siren in English. I would like our kids to change the words to Police Siren in Chinese on the Meowbit TFT screen. Is there a way to import the Chinese characters for Police Siren into “Story” but keep the rest in English? I suppose we could take a screen grab of the characters from Google Translate and make sprite images of them via Pedersen utility and set those sprites to a position but I was wanting to use text if possible; the code is in the description of the video. Thanks

[![](https://img.youtube.com/vi/SPzzb0qCmYY/maxresdefault.jpg "Arcade Police Flashers and Siren; MakeCode, Patrol Bot Car for Starship Fantasy Factory") ](https://www.youtube.com/watch?v=SPzzb0qCmYY)
