Sign in to follow this  
Followers 0
rodent1

Entry of foreign characters, even if there is no numeric keypad

4 posts in this topic

#1 ·  Posted (edited)

For my job, I often have to enter accented foreign characters. The normal Windows method is while pressing Alt, typing a numeric code in the numeric keypad with numlock on. But then, you have to make sure your numlock is on, or the result of your typing may be unpredictable! And if you are using a laptop or a tablet with a tablet keyboard, there is no numeric keypad.

What this script does:

It waits for Win-F6 to start capturing numeric keypress events. The pressed keys are not written, the typed characters are queued. When 4 numbers are queued, the corresponding foreign character is sent to the app.

Also there are a lot of characters, and I don't always remember the numeric code I need. So if I press Win-F7, a gui is displayed, it allows me to pick my font, and I can copy the character I need from there and paste it in my running app.

To compile or run the code, you will have to use the beta run/beta compile etc with autoit 3.3.8.1 or better.

And many thanks to Mikell for his help. Enjoy!

<snip>

Edited by Melba23
Code removed

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

You can just make an input in a loop...maybe use a hotkey to bring up the input:

ClipPut(Chr(InputBox("chrs","add in character code...it will save to buffer")))

example, add 0252 will output: ü

Edited by jdelaney

IEbyXPATH-Grab IE DOM objects by XPATH IEscriptRecord-Makings of an IE script recorder ExcelFromXML-Create Excel docs without excel installed GetAllWindowControls-Output all control data on a given window.

Share this post


Link to post
Share on other sites

You're right, of course, and there would have been less effort creating that kind of script.

I could also have the Windows character map app running, so I can copy and paste the characters I need. No script needed for that.

But if you have to enter a lot of those characters, IMO my system works better.

This hotkey/keyboard hook method allows me to enter them directly from inside the app I'm typing into. Fewer steps, more seamless, I like that.

Share this post


Link to post
Share on other sites

rodent1,

Although I realise ths was not what you intended, what you posted was a keylogger, pure and simple. Please read this announcement to learn what is and is not acceptable here. :naughty:

M23


Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind._______My UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  
Followers 0

  • Similar Content

    • rodent1
      By rodent1
      Hi,
      I often have to enter foreign characters using a us keyboard and the alt keys. But many applications such as browsers react badly to some of the keys, and I end up having to enter them in Notepad and then copying and pasting the characters.
      So I tried to make a hot key script that waits for Win-F6, then hooks the keyboard, and stores the characters in a string. If all the characters are numeric, when there are 4, it should put the corresponding ANSI character into the clipboard and release the keyboard (function ChrW()).
      For example, if I type '0252', it should put 'ü' into the clipboard. But it doesn't till I also exit the script. There are debug tooltip and consolewrite statements, but I'm not getting anywhere. I would appreciate if someone could have a look. Thanks! <snip>
      The code is attached.