How to get the language type of the operating system

Source: Internet
Author: User
Today, the Netizen asked the question:
"For example: when I run on the Chinese version of Win2000, I can get the language version of the operating system in Chinese, when I run it in the Win2000 English version, I know it's English."

Here I write a function for ease of use. (Only get simplified, traditional, and English, others add bar ^_^) The code is as follows:

http://community.csdn.net/Expert/topic/3389/3389759.xml?temp=.2974665

Private Declare Function getsystemdefaultlcid Lib "kernel32" () as Long

Private Sub Command1_Click ()
MsgBox Getostype, vbOKOnly, "hint"
End Sub

Function Getostype () as String
DIM ret as String
Select case Hex (GETSYSTEMDEFAULTLCID)
Case 804:
ret = "Chinese Simplified (mainland)"
Case 404:
ret = "Chinese Traditional (Taiwan)"
Case 409:
ret = "English"
Case Else:
ret = "Other language system"
End Select
Getostype = RET
End Function






Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.