Page 1 of 1

[FIXED] Another UnicodeEncodeError: 'ascii' codec can't enco

Posted: Mon Aug 20, 2007 8:20 am
by zeflash
I was using build 1045 earlier, and I updated it to 1102 in order to see if it could fix another problem (my mistake :) )

I emule my keyboard number keys when I use the MCE remote in many media applications. After updating, most of the number worked, yet 7, 9 and 0 didn't anymore.
From what I can tell those keys (french keyboard layout) are accented (7 = è, 9 = ç and 0 = à).
Weird thing is 2 = é still works fine. Must not be in the same range.

Anyway, here is the copied action:

Code: Select all

<?xml version="1.0" encoding="UTF-8" ?>
<EventGhost Version="1102">
    <Macro Name="9" Expanded="True">
        <Event Name="MceRemote.Num9">
        </Event>
        <Action>
            Window.SendKeys(u'\xe7', False)
        </Action>
    </Macro>
</EventGhost>
And the error:

Code: Select all

MceRemote.Num9
9
Emulate Keystrokes: ç
Error in Action: "Emulate Keystrokes: ç"
Traceback (most recent call last) (1102):
  File "C:\Program Files\EventGhost\plugins\Window\SendKeys.py", line 127, in __call__
  File "C:\Program Files\EventGhost\eg\WinAPI\SendKeys.py", line 430, in Parse
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe7' in position 0: ordinal not in range(128)

Re: Another UnicodeEncodeError: 'ascii' codec can't encode chara

Posted: Tue Aug 21, 2007 2:29 pm
by Bitmonster
=> 0.3.6.1103

Re: Another UnicodeEncodeError: 'ascii' codec can't encode chara

Posted: Thu Aug 23, 2007 1:45 pm
by zeflash
it now works!
thank you :P