Jump to content
Sign in to follow this  

_UniSend("string") - Send a string which includes Unicode characters

Recommended Posts


; Function Name:    _UniSend("string")
; Description:    Sends a string with unicode characters by internally
;           replacing unicode characters with {ASC UNICODEcode}
; Parameter(s):  $uniString - The unicode string.
; Requirement(s):   String Input.
; Return Value(s):  none
; Author:       Praveen Shirali (HydroXidE)

Func _UniSend($uniString)
    Local $i
    For $i = 1 to StringLen($uniString)
        If AscW(StringMid($uniString,$i,1)) > 255 Then
            $uniString = StringLeft($uniString, $i-1) & "{ASC " & AscW(StringMid($uniString, $i, 1)) & "}" & StringMid($uniString, $i+1)
EndFunc  ;==>_UniSend

; *** EXAMPLE ***
$myString = "There's some unicode here --> " & ChrW(8362) & " <--"

WinWaitActive("Document - WordPad")


Simple function. Have fun.

Share this post

Link to post
Share on other sites

I hadn't realized the limitation existed until needed to use Unicode, just tested.

Good job!

There's some unicode here --> ? <--
There's some unicode here --> ¬ <--

Don't bother, It's inside your monitor!------GUISetOnEvent should behave more like HotKeySet()

Share this post

Link to post
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
Sign in to follow this  


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.