>hi sergey
>when i use from this api it is not work in win2000/winxp correctly like in win98
>i use this function in textbox(gotfocus) and when texbox got focus keyboard swithed between righttoleft and lefttoright by parameters (in win98)
>i use win98se arabic edition
>tank sergey
What do you mean, "It doesn't work"? Do you get any error? What is code returned by ActivateKeyboardLayout? If it indicates an error, what the GetLastError function returns? You can try to load first
DECLARE Long LoadKeyboardLayout IN User32 String, Long Flags
kl = LoadKeyboardLayout("00000401",0)
kl_prev = ActivateKeyboardLayout(kl,0)
...
kl_prev = ActivateKeyboardLayout(kl_prev,0)
Can you switch manually, using keyboard shorcut or systray icon?
--sb--