|
|
|
Option Explicit
'ロケールに関する情報を取得
Private Declare Function GetLocaleInfo Lib "kernel32" Alias _
"GetLocaleInfoA" (ByVal Locale As Long, ByVal LCType As Long, _
ByVal lpLCData As String, ByVal cchData As Long) As Long
Private Const LOCALE_SYSTEM_DEFAULT = 2048
Private Const LOCALE_SENGCOUNTRY = &H1002
Private Sub CommandButton1_Click()
Dim buf As String * 256
'API
GetLocaleInfo LOCALE_SYSTEM_DEFAULT, LOCALE_SENGCOUNTRY, buf, 256
'取得した言語を表示
Range("B10") = buf
End Sub
|
|