Jump to content

AutoIT Window Info + Japanese


Guest batkiwi
 Share

Recommended Posts

Guest batkiwi

I'm running some automation on japanese XP. AutoIT itself works GREAT with NO issues. However, when trying to get window info, the window info tool flakes.

Basically what happens is the info appears 100% perfect in the window. However, if I go to copy/paste the japanese text, when I paste it it appears as garbage.

I know it's likely a character encoding issue, but the problem is I can't figure out the encoding the copy/paste is. I tried shift-jis/utf-8/some others, but it never appers correct.

Anyone have any suggestions, such as:

-a workaround

-knowing what encoding copy/paste from the window is

-an alternative tool for getting window/button info

Thanks

Link to comment
Share on other sites

-an alternative tool for getting window/button info...

<{POST_SNAPBACK}>

Try the code below. If the data stays intact, then you should be able to build a script that gathers some of the info that you want and upon hitting the hotkey of your choice, writes the data to the clipboard or to a text file.
HotKeySet("{PAUSE}", "Terminate")

While 1
    $Active_Title = WinGetTitle("")
    ToolTip("Active window's title: " & $Active_Title)
    Sleep(1)
WEnd

Func Terminate()
    ClipPut('WinWait("' & $Active_Title & '", "")')
    Exit
EndFunc  ;==>Terminate
Edited by herewasplato

[size="1"][font="Arial"].[u].[/u][/font][/size]

Link to comment
Share on other sites

Guest batkiwi

Try the code below. If the data stays intact, then you should be able to build a script that gathers some of the info that you want and upon hitting the hotkey of your choice, writes the data to the clipboard or to a text file.

HotKeySet("{PAUSE}", "Terminate")

While 1
    $Active_Title = WinGetTitle("")
    ToolTip("Active window's title: " & $Active_Title)
    Sleep(1)
WEnd

Func Terminate()
    ClipPut('WinWait("' & $Active_Title & '", "")')
    Exit
EndFunc ;==>Terminate

<{POST_SNAPBACK}>

Thanks, thatseems to work. The issue was that I'm running on XP US version, but with japanese enabled and set as default. I just discovered that the tool runs fine on Japanese XP.

Odd eh?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...