Posted on 2005-05-01
Last Modified: 2013-12-03
I have the program named "A" supporting typing in Unicode . For example , I open that program . Then in a editor , when I type a2 , it will become à . More example :
a1  ---> á
a2  ---> à
o6  ---> ô

I have another program written by myself . In this program , I have the string temp = a2 , then I use this function
for (count=0; count<temp.GetLength(); count++)
::PostMessage(hFocus, WM_KEYDOWN, VkKeyScan(temp.GetAt(count)), 0);

I want to write string "à" , not "a2" . The "A" program is already opened . How can I do ?

Question by:hahahahahaha
    LVL 55

    Accepted Solution

    LVL 86

    Assisted Solution


    for (count=0; count<temp.GetLength(); count++)
    ::PostMessageW(hFocus, WM_KEYDOWN, VkKeyScanW(temp.GetAt(count)), 0);

    to enforce using the UNICODE version of teh Win32 APIs. However, you'll have to ensure that 'temp' holds UNICODE data. E.g. ike in

    wchar_t wc = 0xa1;

    ::PostMessageW(hFocus, WM_KEYDOWN, VkKeyScanW(wc), 0);

    Featured Post

    Enabling OSINT in Activity Based Intelligence

    Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

    Join & Write a Comment

    Suggested Solutions

    This article describes how to add a user-defined command button to the Windows 7 Explorer toolbar.  In the previous article (, we saw how to put the Delete button back there where it belongs.  "Delete" is …
    For most people, the WrapPanel seems like a magic when they switch from WinForms to WPF. Most of us will think that the code that is used to write a control like that would be difficult. However, most of the work is done by the WPF engine, and the W…
    This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA.…
    how to add IIS SMTP to handle application/Scanner relays into office 365.

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    12 Experts available now in Live!

    Get 1:1 Help Now