Jump to content

Recommended Posts

Posted

Im wondering if there is a way to have differant languages for buttons. Like in my script, when I try and add a button with the text 한국어, its changes it to ???. Is there a way to make it viewable?

Posted

Im wondering if there is a way to have differant languages for buttons. Like in my script, when I try and add a button with the text 한국어, its changes it to ???. Is there a way to make it viewable?

Take a look at ChrW() and AscW().

I copied your example to the clipboard and ran this code

$sOut = ""
For $I = 1 To StringLen(ClipGet())
$sOut &= ChrW(AscW(StringMid(ClipGet(), $I, 1)))
Next
MsgBox(0, "TEST", $sOut)

The results were as they should be.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Posted (edited)

AscW() gets the Ascii value for the unicode Character

CharW() returns the Unicode character for the given value.

You could also look into using something like this

$aStr = StringToASCIIArray("한국어")
$sStr = StringfromASCIIArray($aStr)
$Gui= GUICreate("Unicode Button TEST")
$Btn = GUICtrlCreateButton($sStr, 20, 20, 80,30)
GUISetState()
While 1
If GUIGetMsg() = - 3 Then ExitLoop
Sleep(10)
Wend

EDIT: Removed a MsgBox

Edited by GEOSoft

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Posted

It worked fine for me with the example I gave you. Try it this way.

Create the following script

$sStr = ClipGet()
$aStr = StringToASCIIArray($sStr)
$sStr = StringfromASCIIArray($aStr)
$Gui= GUICreate("Unicode Button TEST")
$Btn = GUICtrlCreateButton($sStr, 20, 20, 80,30)
GUISetState()
While 1
If GUIGetMsg() = - 3 Then ExitLoop
Sleep(10)
Wend

Now Copy 한국어 to the clipboard and run the script.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Posted (edited)

I think im missing some language files/fonts. :)

I cannot view Chinese (Simplified), Chinese (Traditional), Japanese and Korean. What file would I need for thoes?

Edited by gigilihooie

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
×
×
  • Create New...