Free Web Hosting Provider - Web Hosting - E-commerce - High Speed Internet - Free Web Page
Search the Web

MW-Menu

 

Free Visual BASIC Newsletter

Features

Tips

Sample Code

Newsletters

Products

ActiveX

Cool Links

 

 

 

 

 

 

 

 

 

Determining Whether the Current Keyboard Language Layout is British

This can be simply done by using keyboardlayout identifiers. Below is an example:

Option Explicit

Private Declare Function GetKeyboardLayoutName Lib "user32" Alias

"GetKeyboardLayoutNameA" (ByVal pwszKLID As String) As Long

Private Const KL_NAMELENGTH = 9

Property Get IsBritish() As Boolean

Dim sTemp As String

sTemp = String(KL_NAMELENGTH, 0)

Call GetKeyboardLayoutName(sTemp)

If Left$(sTemp, KL_NAMELENGTH - 1) = "00000809" Then IsBritish = True

End Property

Home

___________________________________________

Send Bugs, comments to the webmaster at webmaster@mwe.8m.com

Terms of Use

© 1999 MW Software, all rights reserved