[Gambas-user] How to Change Keyboard Layout
Gianluigi
bagonergi at gmail.com
Wed Oct 3 15:00:52 CEST 2018
With this code, I'm trying to explain better what I meant to say:
Public Sub TextBox1_GotFocus()
Dim s As String
Desktop.SendKeys("{[Shift_L]6}")
Wait 0.1
s = TextBox1.Text
Print s
Wait 0.1
TextBox1.Clear
If s = "&" Then
Print "Italian keyboard"
Else
Print "Stranger keyboard"
Endif
End
Regards
Gianluigi
Il giorno mer 3 ott 2018 alle ore 09:45 Gianluigi <bagonergi at gmail.com> ha
scritto:
> >Lee, I subscribed to the list you mentioned but should I repeate the same
> thread there or what?
>
> >Charlie, thanks for your answer but it didn't exactly did what I want
> >I'm using Ubuntu
> >the code you put gave me this result: XKBLAYOUT=us,ara
> >what I need to get is the current keyboard layout
> >maybe I wasn't clear while putting my problem, so I"ll try to explain more
> >I want to check my current keyboard layout so if its Arabic, it would be
> changed to English (in >some textboxes) and vices versa.
> >i.e I want to use English in some textboxes and Arabic in others, and I
> want that to be done >through a code to check Keyboard layout and change it
> if needed or keep it if no need to change >it
> >thanks in advance to everyone trying to help
>
> This code that need to do something else, maybe you can direct it to a key
> that makes you understand if the keyboard is 'ara' or 'us'.
>
> Regards
> Gianluigi
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gambas-basic.org/pipermail/user/attachments/20181003/db6dd3a0/attachment.html>
More information about the User
mailing list